Skip to content

Instantly share code, notes, and snippets.

@xinuc
Created April 11, 2011 05:40
Show Gist options
  • Save xinuc/913110 to your computer and use it in GitHub Desktop.
Save xinuc/913110 to your computer and use it in GitHub Desktop.
stupid simple password generator
require 'digest/sha1'
master_password = ARGV[0]
domain = ARGV[1]
digest = Digest::SHA1.hexdigest(master_password + domain)
digest =~ /([^\d])/
puts digest.sub($1, $1.upcase)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment