跳至内容 跳至搜索

一个从密码中派生密钥的 KeyProvider

方法
N

类公共方法

new(passwords, key_generator: ActiveRecord::Encryption.key_generator)

# File activerecord/lib/active_record/encryption/derived_secret_key_provider.rb, line 7
def initialize(passwords, key_generator: ActiveRecord::Encryption.key_generator)
  super(Array(passwords).collect { |password| derive_key_from(password, using: key_generator) })
end