Empty Password Field in /etc/shadow
The next topic I want to cover is verifying that there are no empty passwords in the /etc/shadow file. Why is this important??
Well any account that has an empty password is open for anyone to log into. Part of the security within a Linux system is to ensure that all users are proper users and no one has any authorized access beyond what they need. Open user accounts are security risks that can be easily preventable. One way a hacker could use this is to set up a fake account that has root privileges through sudo. Then anytime they need to access your system they will log on through the fake account and they will never have to remember a password.
One way to check this is to go through the /etc/passwd file and look for any account that might have a blank password in the password space. Another is to use the command
awk -F: `($2 == "") { print $1 }` /etc/shadow
this command will return any user account that has an empty password. If there are no lines returned then your system is safe.
Well any account that has an empty password is open for anyone to log into. Part of the security within a Linux system is to ensure that all users are proper users and no one has any authorized access beyond what they need. Open user accounts are security risks that can be easily preventable. One way a hacker could use this is to set up a fake account that has root privileges through sudo. Then anytime they need to access your system they will log on through the fake account and they will never have to remember a password.
One way to check this is to go through the /etc/passwd file and look for any account that might have a blank password in the password space. Another is to use the command
awk -F: `($2 == "") { print $1 }` /etc/shadow
this command will return any user account that has an empty password. If there are no lines returned then your system is safe.
