LinuxQuestions.org
Support LQ: Use code LQ3 and save $3 on Domain Registration
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices

Reply
 
Search this Thread
Old 04-11-2005, 10:41 AM   #1
AndeAnderson
Member
 
Registered: Feb 2005
Location: Pennsylvania
Distribution: Debian (maybe)
Posts: 235

Rep: Reputation: 30
User name restrictions


It is not critical, but it is a little frustrating.

When trying to set-up secure user names the only restriction I could find was that "it is recommended that the user name start with a lower case character".

But, when I try to set-up secure user names, which use a mix of lower and upper case characters, numbers and symbols I just get an error that the user name is invalid with the message that "the user name "must" (not should) start with a lower case character". Even after correcting this I got the same error message over and over. So, I had to remove all special characters and just use straight names for Linux to accept the user names.

That is not very secure.

What restrictions are there in setting up user names? What symbols, ASCII characters, are not allowed? I do not see anything specified in the books and forums I have searched.

Is there a restriction in the length?
 
Old 04-11-2005, 11:31 AM   #2
pfunk
Member
 
Registered: Jun 2002
Distribution: Suse, Redhat, Knoppix
Posts: 104

Rep: Reputation: 15
I think you're allowed upper and lower case letters, hyphen, underscore and period for usernames in linux.

On most systems I've been on users' home directories are under /home and that directory has world read permission. so if i have an account on the system i can see most everyone's user name. so it wouldn't matter if they had "secure" usernames or not.

Now in terms of outside attacks to your system you're right ... having "secure" usernames is an extra level of security in some way. But I think forcing users to pick good passwords and making them change their passwords often ends up being just as strong.
 
Old 04-11-2005, 11:56 AM   #3
Harmaa Kettu
Member
 
Registered: Apr 2005
Location: Finland
Posts: 196

Rep: Reputation: 30
Comment in the shadow password suite source code:
Code:
/*
 * User/group names must match [a-z_][a-z0-9_-]*
 */
It also accepts a dollar sign, but only as the last character of the username, probably because $letters means an environment variable in bash.

In my own LFS system, I have patched shadow password suite to accept uppercase letters. The only problem I have noticed is that Heroes of the Might and Magic 3 does not find my home directory because of an uppercase letter in directory name. Of course, that is a bug in HOMM3.

The maximum length of usernames seems to be 32 characters.
 
Old 04-11-2005, 02:01 PM   #4
looseCannon
Member
 
Registered: Dec 2003
Location: Little Rock, AR
Distribution: Fedora Core 2, AIX, HP-UX, Solaris, Whitebox
Posts: 193

Rep: Reputation: 31
Quote:
Originally posted by pfunk
On most systems I've been on users' home directories are under /home and that directory has world read permission. so if i have an account on the system i can see most everyone's user name. so it wouldn't matter if they had "secure" usernames or not.
Not necessarily true. Keep in mind that a persons home directory doesn't have to be the same as their username. It can be anything. It's just common practice to make them the same.
 
Old 04-11-2005, 03:29 PM   #5
Tinkster
Moderator
 
Registered: Apr 2002
Location: in a fallen world
Distribution: slackware by choice, others too :} ... android.
Posts: 22,978
Blog Entries: 11

Rep: Reputation: 879Reputation: 879Reputation: 879Reputation: 879Reputation: 879Reputation: 879Reputation: 879
Quote:
Originally posted by Harmaa Kettu
Code:
/*
 * User/group names must match [a-z_][a-z0-9_-]*
 */
In my own LFS system, I have patched shadow password suite to accept uppercase letters. The only problem I have noticed is that Heroes of the Might and Magic 3 does not find my home directory because of an uppercase letter in directory name. Of course, that is a bug in HOMM3.
[/B]
The shadow suite that comes with slackware will happily
accept uppercase and numbers in usernames ... the only thing
that DOESN'T accept them is the useradd program ... if I manually
edit /etc/passwd and /etc/shadow it's all good...


Cheers,
Tink
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
User restrictions on RH9 B|uSmurf Linux - Software 1 10-21-2003 07:24 AM
User and Group access restrictions? KendersPlace Linux - Security 1 08-20-2003 05:32 PM
Restrictions X3781 Linux - General 1 01-07-2003 12:55 PM
setting user restrictions artman62 Linux - Networking 1 08-31-2002 04:49 AM
user Restrictions jpc82 Linux - Security 1 02-04-2002 01:35 AM


All times are GMT -5. The time now is 07:31 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration