1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00
rails--rails/activerecord/lib/active_record/encryption
Jorge Manrubia abfd2cc7a6
Forced encoding for deterministic encryption and other improvements (#42491)
* Fix: re-encrypting will preserve case when ignore_case is used

The implementation was outdated in relation to the new approach where we
override accessors.

* Add support for exists?(...) when querying encrypted attributes

* Add a new option to force encoding for deterministic attributes

Different encodings result in different ciphertexts. For
deterministically encrypted attributes, this can result in having
attributes with the same value that fails to satisfy uniqueness
constraints due to having different encodings.

This adds a new option `forced_encoding_for_deterministic_encryption:`
that will be UTF-8 by default. User can disabled this new behavior by
setting the option to nil.

* Add changelog entry
2021-06-17 12:30:35 +02:00
..
cipher
cipher.rb
config.rb Forced encoding for deterministic encryption and other improvements (#42491) 2021-06-17 12:30:35 +02:00
configurable.rb
context.rb
contexts.rb
derived_secret_key_provider.rb
deterministic_key_provider.rb
encryptable_record.rb Forced encoding for deterministic encryption and other improvements (#42491) 2021-06-17 12:30:35 +02:00
encrypted_attribute_type.rb Forced encoding for deterministic encryption and other improvements (#42491) 2021-06-17 12:30:35 +02:00
encrypted_fixtures.rb
encrypting_only_encryptor.rb
encryptor.rb
envelope_encryption_key_provider.rb
errors.rb
extended_deterministic_queries.rb Forced encoding for deterministic encryption and other improvements (#42491) 2021-06-17 12:30:35 +02:00
extended_deterministic_uniqueness_validator.rb
key.rb
key_generator.rb
key_provider.rb
message.rb
message_serializer.rb
null_encryptor.rb
properties.rb
read_only_null_encryptor.rb
scheme.rb