User Account without a Password
How to allow a user to login without entering a password?
If my question sounds wierd then check out m-net at www.arbornet.org/m-net.php and see how it works. Telnet / SSH to m-net.arbornet.org and type in newuser and it won't prompt for a password. Any ideas? |
just delete their password: passwd -d
|
Why do you want to do so? Using SSH with an ssh-agent wouldn't be an option? Anyway, besides removing the password entry in /etc/shadow, it might also be necessary to adjust in one file in /etc/pam.d to be sure that:
auth required pam_unix2.so nullok has the nullok option. |
well I can see reasons, especially with an account called "newuser"... if it's by extreme exception, and the account is tied to well written provisioning scripts then fine.
|
If you want to remove password of a user you can use passwd -d <username>.
Regards, Aneesh V.M |
Quote:
|
Quote:
I created a user demo and assigned a default password to it. On a different terminal logged in using the login name demo and supplied the password. Things went fine as they would. To enable the user demo login without entering the password, I did what you said: Code:
-bash-2.05b# passwd -d demo Code:
login as: demo I don't want any password for the user "demo" so that it can login without any password. I am not familiar with the PAM thing. |
The PAM thing we have to adjust later. It should simply refuse login for empty passwords by default - although it asks for one, it will always deny access. You are on which OS in detail?
What is the entry for your demo user in /etc/shadow? Are you using NIS, where the old password setting might be still be in it's database (and so removing the password wouldn't act instantly)? |
Quote:
Code:
-bash-2.05b# uname -a Quote:
Code:
Quote:
Code:
No. It is the same server / system. |
When I get you right: it's still asking for a password and you get access by entering the last known one, despite the fact that you deleted the password in the meantime - correct?
NIS can also operate local, do you have something like /var/yp/ ? |
All times are GMT -5. The time now is 10:02 PM. |