class method
self.key_len
Ruby on Rails 4.2.9
Since v4.2.9Signature
self.key_len(cipher = DEFAULT_CIPHER)
Given a cipher, returns the key length of the cipher to help generate the key of desired size
Parameters
-
cipheropt = DEFAULT_CIPHER
Source
# File activesupport/lib/active_support/message_encryptor.rb, line 70
def self.key_len(cipher = DEFAULT_CIPHER)
OpenSSL::Cipher.new(cipher).key_len
end
Defined in activesupport/lib/active_support/message_encryptor.rb line 70
· View on GitHub
· Improve this page
· Find usages on GitHub
Defined in ActiveSupport::MessageEncryptor