Class: Altcha::ChallengeOptions
- Inherits:
-
Object
- Object
- Altcha::ChallengeOptions
- Defined in:
- lib/altcha.rb
Overview
Class representing options for generating a challenge.
Instance Attribute Summary collapse
-
#algorithm ⇒ Object
Returns the value of attribute algorithm.
-
#expires ⇒ Object
Returns the value of attribute expires.
-
#hmac_key ⇒ Object
Returns the value of attribute hmac_key.
-
#max_number ⇒ Object
Returns the value of attribute max_number.
-
#number ⇒ Object
Returns the value of attribute number.
-
#params ⇒ Object
Returns the value of attribute params.
-
#salt ⇒ Object
Returns the value of attribute salt.
-
#salt_length ⇒ Object
Returns the value of attribute salt_length.
Instance Method Summary collapse
-
#initialize(algorithm: nil, max_number: nil, salt_length: nil, hmac_key:, salt: nil, number: nil, expires: nil, params: nil) ⇒ ChallengeOptions
constructor
A new instance of ChallengeOptions.
Constructor Details
#initialize(algorithm: nil, max_number: nil, salt_length: nil, hmac_key:, salt: nil, number: nil, expires: nil, params: nil) ⇒ ChallengeOptions
Returns a new instance of ChallengeOptions.
27 28 29 30 31 32 33 34 35 36 |
# File 'lib/altcha.rb', line 27 def initialize(algorithm: nil, max_number: nil, salt_length: nil, hmac_key:, salt: nil, number: nil, expires: nil, params: nil) @algorithm = algorithm @max_number = max_number @salt_length = salt_length @hmac_key = hmac_key @salt = salt @number = number @expires = expires @params = params end |
Instance Attribute Details
#algorithm ⇒ Object
Returns the value of attribute algorithm.
25 26 27 |
# File 'lib/altcha.rb', line 25 def algorithm @algorithm end |
#expires ⇒ Object
Returns the value of attribute expires.
25 26 27 |
# File 'lib/altcha.rb', line 25 def expires @expires end |
#hmac_key ⇒ Object
Returns the value of attribute hmac_key.
25 26 27 |
# File 'lib/altcha.rb', line 25 def hmac_key @hmac_key end |
#max_number ⇒ Object
Returns the value of attribute max_number.
25 26 27 |
# File 'lib/altcha.rb', line 25 def max_number @max_number end |
#number ⇒ Object
Returns the value of attribute number.
25 26 27 |
# File 'lib/altcha.rb', line 25 def number @number end |
#params ⇒ Object
Returns the value of attribute params.
25 26 27 |
# File 'lib/altcha.rb', line 25 def params @params end |
#salt ⇒ Object
Returns the value of attribute salt.
25 26 27 |
# File 'lib/altcha.rb', line 25 def salt @salt end |
#salt_length ⇒ Object
Returns the value of attribute salt_length.
25 26 27 |
# File 'lib/altcha.rb', line 25 def salt_length @salt_length end |