Class: Mail::Gpg::DecryptedPart
- Inherits:
-
Part
- Object
- Part
- Mail::Gpg::DecryptedPart
- Defined in:
- lib/mail/gpg/decrypted_part.rb
Instance Method Summary collapse
-
#initialize(cipher_part, options = {}) ⇒ DecryptedPart
constructor
options are:.
Constructor Details
#initialize(cipher_part, options = {}) ⇒ DecryptedPart
options are:
:verify: decrypt and verify
8 9 10 11 12 13 14 15 |
# File 'lib/mail/gpg/decrypted_part.rb', line 8 def initialize(cipher_part, = {}) if cipher_part.mime_type != EncryptedPart::CONTENT_TYPE raise EncodingError, "RFC 3136 incorrect mime type for encrypted part '#{cipher_part.mime_type}'" end decrypted = GpgmeHelper.decrypt(cipher_part.body.decoded, ) super(decrypted) end |