On Wed, Aug 3, 2011 at 12:21 PM, Peter Meier <peter.me...@immerda.ch> wrote:
>>> Can someone walk me through the steps of sending out a password to all
>>> my computers for user "student."
>>
>> I do this a lot:
>>
>> yes 'PASSWORD' | passwd username
>>
>> Then you can extract the password from /etc/shadow
>>
>> also  see here:
>>
>> http://serverfault.com/questions/87874/how-should-someone-create-an-encrypted-password-for-etc-shadow
>
>
> No need to go over /etc/shadow or use mkpasswd (which is not available
> that easy on all distros). How about
>
> # salt=`pwgen 8 1`; pass=`pwgen -s 12 1`;ruby -e "puts \
>  ARGV[0].crypt('\$6\$' << ARGV[1] << '\$')" $pass $salt; echo $pass
> $6$eemaihic$3gwFGQxMWE8n/KMZlNe3O9dVoQC5zCXrtabhpCLeDp54eYTGK8WAHovxYZLaQf8YF93Hwfh466CQ966Xoh6O81
> FmstT8KObWVu
>
crypt might yield a different output depending on the c crypt lib, so
in theory it may not work across all os's.

Ohad
> ?
>
> ~pete
>
> --
> You received this message because you are subscribed to the Google Groups 
> "Puppet Users" group.
> To post to this group, send email to puppet-users@googlegroups.com.
> To unsubscribe from this group, send email to 
> puppet-users+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/puppet-users?hl=en.
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Users" group.
To post to this group, send email to puppet-users@googlegroups.com.
To unsubscribe from this group, send email to 
puppet-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/puppet-users?hl=en.

Reply via email to