Class: HttpSignatures::Signature
- Inherits:
-
Object
- Object
- HttpSignatures::Signature
- Defined in:
- lib/http_signatures/signature.rb
Instance Method Summary collapse
-
#initialize(message:, key:, algorithm:, header_list:) ⇒ Signature
constructor
A new instance of Signature.
- #to_str ⇒ Object
Constructor Details
#initialize(message:, key:, algorithm:, header_list:) ⇒ Signature
Returns a new instance of Signature.
4 5 6 7 8 9 |
# File 'lib/http_signatures/signature.rb', line 4 def initialize(message:, key:, algorithm:, header_list:) @message = @key = key @algorithm = algorithm @header_list = header_list end |
Instance Method Details
#to_str ⇒ Object
11 12 13 |
# File 'lib/http_signatures/signature.rb', line 11 def to_str @algorithm.sign(@key.secret, signing_string.to_str) end |