Bash – How should someone create an encrypted password for /etc/shadow

bashencryptionpasswordshadow

I am setting up a new account on a Linux box for Subversion repository access, and can send the password to the new user. However, I think there was a command line utility for this new user to encrypt the password he likes into a format I can copy/paste directly into the /etc/shadow file.

What was the full command that this new user should run on the console (e.g. Bash) to create such an encrypted password?

UPDATE: the user will not be allowed to log in on the machine, and the account will merely be used for svn+ssh:// access. Therefore, the user cannot change it himself.

Best Answer

the user can execute on his computer something like:

echo "password"|openssl passwd -1 -stdin

and then send you the output.