Skip to content

Instantly share code, notes, and snippets.

@toc21c
Last active August 29, 2015 13:58
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save toc21c/9931199 to your computer and use it in GitHub Desktop.
Save toc21c/9931199 to your computer and use it in GitHub Desktop.
#!/usr/bin/env perl
srand(time());
$randletter = "(int (rand (26)) + (int(rand(1) + .5)% 2?65:97))";
$salt = sprintf("%c%c",eval$randletter,eval$randletter);
$plaintext =shift;
$crypttext = crypt ($plaintext,$salt);
print "${crypttext}\n";
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment