Class: Confium::CryptoError
- Inherits:
-
Error
- Object
- Error
- Confium::CryptoError
- Defined in:
- lib/confium/errors/crypto_error.rb
Overview
Raised when a primitive-level crypto operation fails (invalid scalar, bad key derivation).
Instance Attribute Summary collapse
-
#primitive ⇒ Object
readonly
Returns the value of attribute primitive.
Instance Method Summary collapse
-
#initialize(message = nil, details_hash = nil, **kwargs) ⇒ CryptoError
constructor
A new instance of CryptoError.
Constructor Details
#initialize(message = nil, details_hash = nil, **kwargs) ⇒ CryptoError
Returns a new instance of CryptoError.
8 9 10 11 12 |
# File 'lib/confium/errors/crypto_error.rb', line 8 def initialize( = nil, details_hash = nil, **kwargs) , kwargs = Confium::Errors::Coerce.args(, details_hash, kwargs) @primitive = kwargs.delete(:primitive) super(, details: { primitive: @primitive, **kwargs }) end |
Instance Attribute Details
#primitive ⇒ Object (readonly)
Returns the value of attribute primitive.
6 7 8 |
# File 'lib/confium/errors/crypto_error.rb', line 6 def primitive @primitive end |