Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
require 'digest/sha1'
require 'base64'
d = Digest::SHA1.new
hash = Base64.encode64(d.digest('something secret'))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment