Problem/Motivation
When creating hashes we should use a salt created from the hash salt and private key. At the moment \Drupal\Core\Entity\Element\EntityAutocomplete::processEntityAutocomplete only uses the hash salt.
Proposed resolution
Add the private key to the salt.
Remaining tasks
Discuss how to make this BC compatible.
@chr.fritsch pointed out in #3057314-11: Harden hash checking in core that
But I have one concern and I am not sure if this falls under the BC policy. In processEntityAutocomplete we are changing the way how the $selection_settings_key is created.
In the select2 module, I am calling EntityAutocomplete::processEntityAutocomplete($element, new FormState(), $complete_form) and I have implemented my own EntityAutocompleteController. That means the hashes will not match anymore there.
So this change will break select2 and I am not able to make the select2 module 8.7 and 8.8 compatible without implementing my own processEntityAutocomplete method.
User interface changes
None
API changes
@tbd
Data model changes
None
Release notes snippet
@todo
| Comment | File | Size | Author |
|---|---|---|---|
| #9 | 3058396-9.patch | 4.44 KB | ranjith_kumar_k_u |
| #8 | 3058396-8.patch | 4.42 KB | ranjith_kumar_k_u |
| #2 | 3058396-2.patch | 4.47 KB | alexpott |
Comments
Comment #2
alexpottHere's patch. We still need to address the BC aspects. Not sure how though.
Comment #8
ranjith_kumar_k_u commentedRe-rolled for 9.4.
Comment #9
ranjith_kumar_k_u commented