You have a few misconceptions, both on how the login system works and what the purpose of these accounts is.
First, most of these accounts, with the exception of
eric, are system accounts that are not meant for people to login but allow different services to run as ordinary users without all the privileges the
root account has. As an example, the OpenSSH daemon usually runs as user
sshd, so if anyone would manage to gain control over the
sshd process, it would allow him only to access and modify the files for which the corresponding user
sshd has permissions.
Second, the preferred way to disable login for a user is to disable his password and not to change the login shell to
/bin/false. On modern Linux systems, the user database actually consists of two parts,
/etc/shadow. The password is stored in
/etc/shadow (see below for why), and an account is disabled if its password field in
/etc/shadow is an
In the following example, the user
sshd is disabled, while
sven has an encrypted password set. You can't login as user
sshd, neither via the console nor an ssh session, but login for
sven will work.
Most likely, you will find that all users on your system, with the exception of
eric (and maybe
root) are disabled this way, which means that what you want to accomplish has already been done by the developers. Also, you will find that many accounts also have their login shell already set to
/etc/passwd, which means that even root can't use `su' to switch to these accounts.
Why the separation of
Many programs need to access the user database for various purposes, but giving read access to
/etc/passwd allowed everyone to read the encrypted passwords of all users, which is highly insecure, especially as the encryption of the passwords was quite weak for a long time. This was solved by putting the passwords into the separate file
/etc/shadow, which is only readable by root.