Skip to content

Instantly share code, notes, and snippets.

@kgriffs
Created March 2, 2012 16:49
Show Gist options
  • Save kgriffs/1959600 to your computer and use it in GitHub Desktop.
Save kgriffs/1959600 to your computer and use it in GitHub Desktop.
Encrypting a password with an RSA key on Linux
read -s -p "Password: " qpwd
echo $qpwd | openssl rsautl -encrypt -inkey public-key.pem -pubin | openssl base64
unset qpwd
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment