Skip to content

Instantly share code, notes, and snippets.

@prasmussen
Created June 15, 2012 10:15
Show Gist options
  • Save prasmussen/2935739 to your computer and use it in GitHub Desktop.
Save prasmussen/2935739 to your computer and use it in GitHub Desktop.
Smartos shadow hash generator
#!/bin/bash
read -s -p "New Password: " password
echo
read -s -p "Re-enter new Password: " confirm
echo
if [ "$password" != "$confirm" ]; then
echo "Password don't match!"
exit 1
fi
/usr/lib/cryptpass "$password"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment