LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - General (https://www.linuxquestions.org/questions/linux-general-1/)
-   -   /etc/passwd (https://www.linuxquestions.org/questions/linux-general-1/etc-passwd-333071/)

XaViaR 06-13-2005 09:44 AM

/etc/passwd
 
Hello,

Below is my passwd file. I was wondering why is there other accounts installed by default? And, why would they have /bin/sh as their shell? Isn't that a security hole? Should I switch their shell to /bin/false? Will that break anything?

root:x:0:0:root:/root:/bin/bash
bin:x:1:1:bin:/bin:/bin/bash
daemon:x:2 : 2 : Daemon:/sbin:/bin/bash
lp:x:4:7:Printing daemon:/var/spool/lpd:/bin/bash
mail:x:8:12:Mailer daemon:/var/spool/clientmqueue:/bin/false
news:x:9:13:News system:/etc/news:/bin/bash
uucp:x:10:14:Unix-to-Unix CoPy system:/etc/uucp:/bin/bash
games:x:12:100:Games account:/var/games:/bin/bash
man:x:13:62:Manual pages viewer:/var/cache/man:/bin/bash
at:x:25:25:Batch jobs daemon:/var/spool/atjobs:/bin/bash
wwwrun:x:30:8:WWW daemon apache:/var/lib/wwwrun:/bin/false
ftp:x:40:49:FTP account:/srv/ftp:/bin/bash
postfix:x:51:51:Postfix Daemon:/var/spool/postfix:/bin/false
sshd:x:71:65:SSH daemon:/var/lib/sshd:/bin/false
nobody:x:65534:65533:nobody:/var/lib/nobody:/bin/bash
syslogng:x:1001:100:syslog-ng:/home/syslog-ng:/bin/false

Thanks for your help,

-X

AdamJacobMuller 06-13-2005 10:12 AM

there are many accounts installed by default on even the most basic Unix install.
This is a good thing.
What it means is that every one of those programs will be working (at least in part) as a normal user instead of as root which increases the security of your system.
As for /bin/sh being set as the shell. I don't like this and have sucessfully changed many of those entries to to use /bin/false or /sbin/nologin et al. However this *really* isn't a security hole since if you look @ /etc/shadow you will notice that all of those users have "*" as a password. That basically disables any password-based login so /bin/sh as a shell isn't really insecure.


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