Exception: Quonfig::Errors::DecryptionError
- Inherits:
-
Quonfig::Error
- Object
- StandardError
- Quonfig::Error
- Quonfig::Errors::DecryptionError
- Defined in:
- lib/quonfig/errors/decryption_error.rb
Overview
Raised when a confidential config’s ciphertext cannot be decrypted —either the configured ‘decryptWith` key is missing/empty, or the AES-GCM payload itself is malformed/tampered.
Mirrors sdk-python’s QuonfigDecryptionError. Sdk-node currently raises plain ‘Error` for the same path; this class is the Ruby equivalent of the dedicated exception type.
Instance Method Summary collapse
-
#initialize(key, cause = nil) ⇒ DecryptionError
constructor
A new instance of DecryptionError.
Constructor Details
#initialize(key, cause = nil) ⇒ DecryptionError
Returns a new instance of DecryptionError.
13 14 15 16 17 |
# File 'lib/quonfig/errors/decryption_error.rb', line 13 def initialize(key, cause = nil) = "Decryption failed for config '#{key}'" += ": #{cause}" if cause && !cause.to_s.empty? super() end |