>Number: 182703 >Category: bin >Synopsis: [patch] camcontrol(8) security command can't set master >password >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Sat Oct 05 16:50:00 UTC 2013 >Closed-Date: >Last-Modified: >Originator: Scott Burns >Release: 9.2-RELEASE >Organization: BQ Internet Corporation >Environment: FreeBSD backup19.bqinternet.com 9.2-RELEASE FreeBSD 9.2-RELEASE #2: Sat Oct 5 11:25:27 UTC 2013 r...@backup19.bqinternet.com:/usr/obj/usr/src/sys/BACKUP19 amd64 >Description: FreeBSD 9.2 introduced support for ATA security settings in camcontrol(8). The released version of camcontrol is unable to set a master password due to a bug in the command-line option parsing. >How-To-Repeat: # camcontrol security da18 -U master -s 0000 camcontrol: -U argument 'master' is invalid (must be 'user' or 'master') >Fix: See attached patch.
Patch attached with submission follows: --- sbin/camcontrol/camcontrol.c.orig 2013-10-05 16:19:28.000000000 +0000 +++ sbin/camcontrol/camcontrol.c 2013-10-05 16:22:49.477413000 +0000 @@ -2748,7 +2748,7 @@ if (strcasecmp(optarg, "user") == 0) { pwd.ctrl |= ATA_SECURITY_PASSWORD_USER; pwd.ctrl &= ~ATA_SECURITY_PASSWORD_MASTER; - } else if (strcasecmp(optarg, "master") != 0) { + } else if (strcasecmp(optarg, "master") == 0) { pwd.ctrl |= ATA_SECURITY_PASSWORD_MASTER; pwd.ctrl &= ~ATA_SECURITY_PASSWORD_USER; } else { >Release-Note: >Audit-Trail: >Unformatted: _______________________________________________ freebsd-bugs@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-bugs To unsubscribe, send any mail to "freebsd-bugs-unsubscr...@freebsd.org"