From owner-freebsd-stable Sat Jun 10 18:29:19 2000 Delivered-To: freebsd-stable@freebsd.org Received: from epsilon.lucida.qc.ca (epsilon.lucida.qc.ca [216.95.146.6]) by hub.freebsd.org (Postfix) with SMTP id 5BEEC37B534 for ; Sat, 10 Jun 2000 18:29:15 -0700 (PDT) (envelope-from matt@ARPA.MAIL.NET) Received: (qmail 13904 invoked by uid 1000); 11 Jun 2000 01:29:13 -0000 Received: from localhost (sendmail-bs@127.0.0.1) by localhost with SMTP; 11 Jun 2000 01:29:13 -0000 Date: Sat, 10 Jun 2000 21:29:10 -0400 (EDT) From: Matt Heckaman X-Sender: matt@epsilon.lucida.qc.ca To: William Wong Cc: freebsd-stable@freebsd.org Subject: Re: rmuser bug In-Reply-To: <000f01bfd33f$597b0ca0$0300a8c0@anime.ca> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Spam-Rating: localhost 1.6.2 0/1000/N Sender: owner-freebsd-stable@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 If I'm not mistaken, the default adduser doesn't allow you to add a username with '-' character (not to mention qmail doesn't like it) I don't use either default adduser|rmuser but I think my memory serves. Regards, Matt On Sat, 10 Jun 2000, William Wong wrote: : Date: Sat, 10 Jun 2000 20:52:41 -0400 : From: William Wong : To: freebsd-stable@freebsd.org : Subject: rmuser bug : : Hi there, : : I noticed a small bug in the rmuser script version: : (# $FreeBSD: src/usr.sbin/adduser/rmuser.perl,v 1.8.2.1 2000/03/20 13:00:36 : peter Exp $) : ... which prevents you from deleting usernames which contain the dash ('-') : character. : : There was a similar check done later on in the code, so I just modified it a : bit to match (since I don't know much about perl and expressions :) I'm not : sure if it's been fixed though in the most current/stable version though. : : - Will : : There's a line of code that reads: : : if ($#ARGV == 0) : : # Username was given as a parameter : $login_name = pop(@ARGV); : die "Sorry, login name must contain alphanumeric characters only.\n" : if ($login_name !~ /^[a-zA-Z0-9_]\w*$/); : } : : ... when it should read: : : if ($#ARGV == 0) : : # Username was given as a parameter : $login_name = pop(@ARGV); : die "Sorry, login name must contain alphanumeric characters only.\n" : if ($login_name !~ /^[a-z0-9_][a-z0-9_\-]*$/); : } : : : : To Unsubscribe: send mail to majordomo@FreeBSD.org : with "unsubscribe freebsd-stable" in the body of the message : Matt Heckaman matt@arpa.mail.net http://www.lucida.qc.ca -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.0.1 (FreeBSD) Comment: http://www.lucida.qc.ca/pgp iD8DBQE5QutpdMMtMcA1U5ARApX9AKChihgPVAtjqtHZJ7yGlFtA/QMjAgCg5S0q NgJoYik2VU0dRaNWJQl2ZAo= =UUv2 -----END PGP SIGNATURE----- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-stable" in the body of the message