Class: Ronin::Support::Crypto::Cipher::AES
- Inherits:
-
Ronin::Support::Crypto::Cipher
- Object
- OpenSSL::Cipher
- Ronin::Support::Crypto::Cipher
- Ronin::Support::Crypto::Cipher::AES
- Defined in:
- lib/ronin/support/crypto/cipher/aes.rb
Overview
The AES cipher.
Instance Attribute Summary collapse
-
#key_size ⇒ Integer
readonly
The AES cipher key size.
-
#mode ⇒ :cbc, ...
readonly
The AES cipher mode.
Class Method Summary collapse
-
.supported ⇒ Array<String>
The list of supported AES ciphers.
Instance Method Summary collapse
-
#initialize(key_size:, mode: :cbc, **kwargs) ⇒ AES
constructor
Initializes the AES cipher.
Methods inherited from Ronin::Support::Crypto::Cipher
Constructor Details
#initialize(key_size:, mode: :cbc, **kwargs) ⇒ AES
Initializes the AES cipher.
53 54 55 56 57 58 |
# File 'lib/ronin/support/crypto/cipher/aes.rb', line 53 def initialize(key_size: , mode: :cbc, **kwargs) super("aes-#{key_size}-#{mode}", **kwargs) @key_size = key_size @mode = mode end |
Instance Attribute Details
#key_size ⇒ Integer (readonly)
The AES cipher key size.
34 35 36 |
# File 'lib/ronin/support/crypto/cipher/aes.rb', line 34 def key_size @key_size end |
#mode ⇒ :cbc, ... (readonly)
The AES cipher mode.
39 40 41 |
# File 'lib/ronin/support/crypto/cipher/aes.rb', line 39 def mode @mode end |