From owner-freebsd-bugs Wed Aug 21 16:20:34 2002 Delivered-To: freebsd-bugs@hub.freebsd.org Received: from mx1.FreeBSD.org (mx1.FreeBSD.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 7277237B405 for ; Wed, 21 Aug 2002 16:20:07 -0700 (PDT) Received: from freefall.freebsd.org (freefall.FreeBSD.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id B743A43E4A for ; Wed, 21 Aug 2002 16:20:06 -0700 (PDT) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.12.4/8.12.4) with ESMTP id g7LNK6JU002132 for ; Wed, 21 Aug 2002 16:20:06 -0700 (PDT) (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.12.4/8.12.4/Submit) id g7LNK6mo002131; Wed, 21 Aug 2002 16:20:06 -0700 (PDT) Received: from mx1.FreeBSD.org (mx1.FreeBSD.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id E914037B400 for ; Wed, 21 Aug 2002 16:19:19 -0700 (PDT) Received: from mta02-srv.alltel.net (mta02.alltel.net [166.102.165.144]) by mx1.FreeBSD.org (Postfix) with ESMTP id E618743E84 for ; Wed, 21 Aug 2002 16:19:18 -0700 (PDT) (envelope-from cd9@buffalo.edu) Received: from selvirjin.alltel.net ([166.102.201.65]) by mta02-srv.alltel.net with ESMTP id <20020821231917.TGZB28341.mta02-srv.alltel.net@selvirjin.alltel.net> for ; Wed, 21 Aug 2002 18:19:17 -0500 Received: from dragon by selvirjin.alltel.net with local (Exim 3.36 #1) id 17hekR-000172-00; Wed, 21 Aug 2002 19:18:47 -0400 Message-Id: <20020821191847.A87558@selvirjin.alltel.net> Date: Wed, 21 Aug 2002 19:18:47 -0400 From: cd9@buffalo.edu Reply-To: cd9@buffalo.edu To: FreeBSD-gnats-submit@FreeBSD.org Cc: cd9@buffalo.edu X-Send-Pr-Version: 3.113 Subject: bin/41870: [PATCH] atacontrol reports SMART settings for "security" Sender: owner-freebsd-bugs@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org >Number: 41870 >Category: bin >Synopsis: [PATCH] atacontrol reports SMART settings for "security" >Confidential: no >Severity: non-critical >Priority: medium >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Wed Aug 21 16:20:06 PDT 2002 >Closed-Date: >Last-Modified: >Originator: C. A. Daelhousen >Release: FreeBSD 4.6-STABLE i386 >Organization: >Environment: System: FreeBSD selvirjin.alltel.net 4.6-STABLE FreeBSD 4.6-STABLE #2: Wed Aug 21 13:21:57 EDT 2002 root@selvirjin.alltel.net:/usr/obj/usr/src/sys/V8 i386 >Description: In /usr/src/sbin/atacontrol/atacontrol.c v1.11.2.5, function cap_print, line 161: For "security", the printf statement uses the values of parm->support.smart and parm->enabled.smart rather than parm->support.security and parm->enabled.security. >How-To-Repeat: Unknown--the problem was spotted while reading source. Presumably, running "atacontrol cap" on a device that has either SMART or security (but not both) enabled or supported would show the bug. >Fix: Caveat: I'm a novice at operating diff. Check the headers before use. Times are UTC -0400. Patch against src/sbin/atacontrol/atacontrol.c,v 1.11.2.5: --- src/sbin/atacontrol/atacontrol.c Wed Aug 21 11:24:21 2002 +++ src/sbin/atacontrol/atacontrol-patched.c Wed Aug 21 15:15:04 2002 @@ -158,8 +158,8 @@ parm->enabled.microcode ? "yes" : "no"); printf("security %s %s\n", - parm->support.smart ? "yes" : "no", - parm->enabled.smart ? "yes" : "no"); + parm->support.security ? "yes" : "no", + parm->enabled.security ? "yes" : "no"); printf("power management %s %s\n", parm->support.power_mngt ? "yes" : "no", >Release-Note: >Audit-Trail: >Unformatted: To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message