From owner-freebsd-stable Sat Jun 10 17:52:55 2000 Delivered-To: freebsd-stable@freebsd.org Received: from maildrop.velocet.net (maildrop.velocet.net [216.126.74.5]) by hub.freebsd.org (Postfix) with ESMTP id 1C42A37B960 for ; Sat, 10 Jun 2000 17:52:47 -0700 (PDT) (envelope-from willwong@anime.ca) Received: from magus (H45.C55.tor.velocet.net [204.138.55.45]) by maildrop.velocet.net (Postfix) with SMTP id 6315278202 for ; Sat, 10 Jun 2000 20:52:42 -0400 (EDT) Message-ID: <000f01bfd33f$597b0ca0$0300a8c0@anime.ca> From: "William Wong" To: Subject: rmuser bug Date: Sat, 10 Jun 2000 20:52:41 -0400 MIME-Version: 1.0 Content-Type: text/plain; charset="Windows-1252" Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 5.00.2919.6600 X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2919.6600 Sender: owner-freebsd-stable@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG 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