Class: AtprotoAuth::DPoP::NonceManager::StoredNonce
- Inherits:
-
Object
- Object
- AtprotoAuth::DPoP::NonceManager::StoredNonce
- Defined in:
- lib/atproto_auth/dpop/nonce_manager.rb
Overview
Represents a stored nonce with its server URL
Instance Attribute Summary collapse
-
#server_url ⇒ Object
readonly
Returns the value of attribute server_url.
-
#timestamp ⇒ Object
readonly
Returns the value of attribute timestamp.
-
#value ⇒ Object
readonly
Returns the value of attribute value.
Instance Method Summary collapse
-
#initialize(value, server_url, timestamp: nil) ⇒ StoredNonce
constructor
A new instance of StoredNonce.
Constructor Details
#initialize(value, server_url, timestamp: nil) ⇒ StoredNonce
Returns a new instance of StoredNonce.
16 17 18 19 20 |
# File 'lib/atproto_auth/dpop/nonce_manager.rb', line 16 def initialize(value, server_url, timestamp: nil) @value = value @server_url = server_url = || Time.now.to_i end |
Instance Attribute Details
#server_url ⇒ Object (readonly)
Returns the value of attribute server_url.
14 15 16 |
# File 'lib/atproto_auth/dpop/nonce_manager.rb', line 14 def server_url @server_url end |
#timestamp ⇒ Object (readonly)
Returns the value of attribute timestamp.
14 15 16 |
# File 'lib/atproto_auth/dpop/nonce_manager.rb', line 14 def end |
#value ⇒ Object (readonly)
Returns the value of attribute value.
14 15 16 |
# File 'lib/atproto_auth/dpop/nonce_manager.rb', line 14 def value @value end |