Nasser Heidari


Creating an encrypted password

Filed under: Linux — Nasser Heidari @ 18:50

If you want to add a user to linux system , normaly you need to add user and then assign a password to user with passwd command .

you can use -p switch while adding user to assign password , but you need to pass an encrypted password .

there is a two way for creating encrypted password:

#openssl passwd -1 <MYPASS>

# useradd -p ‘$1$ZZLfAZpL$mwVBijRFpr0EBBk3l7nY8.’ nasser


#perl -e ‘print crypt(“password”, “MYPASS”),”\n”‘

# useradd -p ‘MYhWg5VCf/bwA’ nasser


Leave a Comment »

No comments yet.

RSS feed for comments on this post. TrackBack URI

Leave a Reply

Please log in using one of these methods to post your comment: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

%d bloggers like this: