From owner-freebsd-bugs@FreeBSD.ORG Tue Nov 9 18:30:12 2010 Return-Path: Delivered-To: freebsd-bugs@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 4817D106566C for ; Tue, 9 Nov 2010 18:30:12 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id 061948FC19 for ; Tue, 9 Nov 2010 18:30:12 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.4/8.14.4) with ESMTP id oA9IUB8C073538 for ; Tue, 9 Nov 2010 18:30:11 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.4/8.14.4/Submit) id oA9IUBXP073536; Tue, 9 Nov 2010 18:30:11 GMT (envelope-from gnats) Resent-Date: Tue, 9 Nov 2010 18:30:11 GMT Resent-Message-Id: <201011091830.oA9IUBXP073536@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-bugs@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Jan Schaumann Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 2D88F106566C for ; Tue, 9 Nov 2010 18:24:33 +0000 (UTC) (envelope-from nobody@FreeBSD.org) Received: from www.freebsd.org (www.freebsd.org [IPv6:2001:4f8:fff6::21]) by mx1.freebsd.org (Postfix) with ESMTP id 1C2E78FC12 for ; Tue, 9 Nov 2010 18:24:33 +0000 (UTC) Received: from www.freebsd.org (localhost [127.0.0.1]) by www.freebsd.org (8.14.3/8.14.3) with ESMTP id oA9IOWac094764 for ; Tue, 9 Nov 2010 18:24:32 GMT (envelope-from nobody@www.freebsd.org) Received: (from nobody@localhost) by www.freebsd.org (8.14.3/8.14.3/Submit) id oA9IOWXY094751; Tue, 9 Nov 2010 18:24:32 GMT (envelope-from nobody) Message-Id: <201011091824.oA9IOWXY094751@www.freebsd.org> Date: Tue, 9 Nov 2010 18:24:32 GMT From: Jan Schaumann To: freebsd-gnats-submit@FreeBSD.org X-Send-Pr-Version: www-3.1 Cc: Subject: misc/152084: pw(8) does not allow @ or ! in gecos X-BeenThere: freebsd-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 09 Nov 2010 18:30:12 -0000 >Number: 152084 >Category: misc >Synopsis: pw(8) does not allow @ or ! in gecos >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: Tue Nov 09 18:30:11 UTC 2010 >Closed-Date: >Last-Modified: >Originator: Jan Schaumann >Release: >Organization: >Environment: >Description: pw(8) does not allow you to add a user with a ! or a @ in the gecos field. I have not been able to find any standard mentioning these as invalid characters, nor do various other unix flavors implement this restriction. >How-To-Repeat: pw user add -n name -u uid -g gid -d dir -s shell -c"Something with an @ in it" >Fix: --- pw_user.c.orig Tue Nov 9 10:22:10 2010 +++ pw_user.c Tue Nov 9 10:24:01 2010 @@ -1172,7 +1172,7 @@ reject = 0; if (gecos) { /* See if the name is valid as a gecos (comment) field. */ - badchars = ":!@"; + badchars = ":"; showtype = "gecos field"; } else { /* See if the name is valid as a userid or group. */ >Release-Note: >Audit-Trail: >Unformatted: