EncryptDataObjectFieldsExtension::updateFieldEncryptionKey
Checks whether the owner DataObject has a provideEncryptionKey() method and if it does, passes the encryption key returned by that method to $field. This makes the encryption (and decryption) to use a custom key rather than the global ENCRYPT_AT_REST_KEY key.
If provideEncryptionKey() returns null, then the field will use the default key instead of a custom one.
Signature
private function updateFieldEncryptionKey(DBField
$field )
Parameters
$field
— DBField- The field where the (possible) custom key should be applied to.