diff options
author | 1995-04-30 19:20:25 +0000 | |
---|---|---|
committer | 1995-04-30 19:20:25 +0000 | |
commit | 54314e8b40c035b3b3df6ea35ae37c4753d95d6b (patch) | |
tree | f93b3e10f4ff5cb9dd01a5ea29a5a51b717d2de7 /adduser | |
parent | 00b750936d25ae68539e0c9db2839d9318db878c (diff) | |
download | pw-darwin-54314e8b40c035b3b3df6ea35ae37c4753d95d6b.tar.gz pw-darwin-54314e8b40c035b3b3df6ea35ae37c4753d95d6b.tar.zst pw-darwin-54314e8b40c035b3b3df6ea35ae37c4753d95d6b.zip |
Don't accept usernames longer than 8 characters
Submitted by: Wolfram Schneider <wosch@cs.tu-berlin.de>
Diffstat (limited to 'adduser')
-rw-r--r-- | adduser/adduser.perl | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/adduser/adduser.perl b/adduser/adduser.perl index aefe84a..ab09e1d 100644 --- a/adduser/adduser.perl +++ b/adduser/adduser.perl @@ -32,7 +32,7 @@ # # Email: Wolfram Schneider <wosch@cs.tu-berlin.de> # -# $Id: adduser.perl,v 1.4 1995/03/08 22:44:37 ache Exp $ +# $Id: adduser.perl,v 1.5 1995/04/09 03:34:10 ache Exp $ # # read variables @@ -306,6 +306,10 @@ sub new_users_name { while(1) { $name = &confirm_list("Enter username", 1, "a-z0-9", ""); + if (length($name) > 8) { + warn "Username is longer than 8 chars\a\n"; + next; + } last if (&new_users_name_valid($name) eq $name); } return $name; |