LinuxQuestions.org
Visit the LQ Articles and Editorials section
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices

Reply
 
Search this Thread
Old 08-25-2004, 03:14 AM   #1
sheetal_govekar
LQ Newbie
 
Registered: Aug 2004
Location: Goa, India
Posts: 1

Rep: Reputation: 0
'Can a user be created with username as "/dev/null" in an application?'


In a web based application written using perl there is a facility to create user. So should it allow the application user to enter user name as "/dev/null"
 
Old 08-25-2004, 11:31 AM   #2
rjlee
Senior Member
 
Registered: Jul 2004
Distribution: Ubuntu 7.04
Posts: 1,990

Rep: Reputation: 67
If you're talking about a user of the system, then no. / is not a valid character in a UNIX username as far as I'm aware.

I wouldn't expect a web-based application to work like that. It's almost certainly going to be running as user nobody, who should not have permissions to create new system users.

Are you sure it's not just creating a database of “usernames” internal to the app? In which case, it would depend entirely on the app, and how the username is used. If it's creating a file with the username, then you really don't want let it contain a / as that could put the file into a different directory — somewhat of an administrative nightmare.

To err on the safe side, I say “no”. But without seeing the app, or knowing how the entered string is used, I can't be sure.

Edit: If you're creating a file based on the username then this is fine so long as / is escaped to something else in the filename. You can't just use C-style backslash-escaping as / cannot occur in a *NIX filename at all (although \ itself can, so you could do something by replacing / with \ )

Last edited by rjlee; 08-27-2004 at 01:19 PM.
 
  


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
Why "bash-2.05b$" in Terminal instead of "username@localhost username" jayelitumbiolo Linux - General 9 10-04-2009 03:16 AM
what is the "default" user created by zope on install? eantoranz Ubuntu 4 09-16-2005 12:49 PM
Platform-independent "/dev/null" stream redirection? wapcaplet Programming 1 08-12-2005 10:11 PM
/sbin/adsl-start: line 215: 5543 Terminated $CONNECT "$@" >/dev/null 2> ciberrust Linux - Hardware 3 03-27-2005 10:38 AM
RH "null" beta system freezes right after printing "INIT" markus1982 Linux - Hardware 0 09-09-2002 03:31 PM


All times are GMT -5. The time now is 06:54 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