Class: Trocla::Formats::Sha1
Instance Attribute Summary
Attributes inherited from Base
Instance Method Summary collapse
Methods inherited from Base
expensive, #expensive?, expensive?, #initialize, #render
Constructor Details
This class inherits a constructor from Trocla::Formats::Base
Instance Method Details
#format(plain_password, options = {}) ⇒ Object
4 5 6 |
# File 'lib/trocla/formats/sha1.rb', line 4 def format(plain_password, = {}) '{SHA}' + Base64.encode64(Digest::SHA1.digest(plain_password)) end |