- Issue created by @nico.b
- 🇺🇸United States caesius
This was solved for case sensitivity by adding the function
caseInsensitiveArrayIntersect()
. Maybe that should be replaced/updated with a function that instead uses something likeiconv()
as suggested here https://stackoverflow.com/questions/471021/comparing-strings-in-php-the-... - 🇳🇿New Zealand quietone
Changes are made on on 11.x (our main development branch) first, and are then back ported as needed according to our policies.
- 🇮🇳India arunkumark Coimbatore
The issue seems the same as 🐛 Able to create user accounts with the same email address Active . On the issue, it was trying to handle the case insensitively with mb_strtoupper(). But am unable to match the words example and éxample.
Below is the observation received on
ISO-8859-1//TRANSLIT
as per https://stackoverflow.com/questions/471021/comparing-strings-in-php-the-...echo iconv('UTF-8', 'ISO-8859-1//TRANSLIT', 'éxample'); // Output is �xample
I tried this
ASCII//TRANSLIT
is working as fine. As per, https://stackoverflow.com/questions/24504331/how-to-compare-two-strings-...
echo iconv('UTF-8', 'ASCII//TRANSLIT', 'éxample'); // Output is example
Creating as MR as per the above suggestion. Feel free to update the MR.
- 🇺🇸United States caesius
It sounds like this was probably fixed in the latest Drupal core update, although the vulnerability is only detailed for email addresses, not usernames. https://www.drupal.org/sa-core-2024-004 →
- 🇮🇳India arunkumark Coimbatore
@caesius
Hope the issue with the page break. Still, the issue persists after the https://www.drupal.org/sa-core-2024-004 → patch moved. I can replicate it today also on the latest pull.Hope the issue persists, to handle the exception.
- 🇺🇸United States smustgrave
Issue summary is missing template sections.
left other comments on MR.
- 🇮🇳India arunkumark Coimbatore
As per the #12 comment updated the Issue summary and addressed the changes requested in MR. The pipeline has passed and is moving to NR.
- 🇺🇸United States smustgrave
All the open threads still apply so leaving in review.
- 🇺🇸United States smustgrave
1 open thread, tagging for novice as it should be easy for a new user to address.
- Status changed to Needs work
5 months ago 3:10pm 25 February 2025 - 🇭🇺Hungary mxr576 Hungary
@nico.b told me that my 🐛 User names uniqueness is no longer accent-sensitive Active is actually is a duplicate of this one - I do not know how I did not find this one back at the time, but thanks for intel Nico.
In that issue I had a very similar fix that is being proposed here and because I saw test failures on MR for other database engines than MariaDB and MYSQL, I have also triggered test runs on those db engines here and they failed too. So the proposed fix actually needs work:
core/tests/Drupal/KernelTests/Core/Validation/UniqueValuesConstraintValidatorTest.php Drupal\KernelTests\Core\Validation\UniqueValuesConstraintValidatorTest::testUsernameUniqueValidation Failed asserting that actual size 0 matches expected size 1. core/tests/Drupal/KernelTests/Core/Validation/UniqueValuesConstraintValidatorTest.php:359
(source: https://git.drupalcode.org/issue/drupal-3456964/-/pipelines/433653/test_...)
- 🇭🇺Hungary mxr576 Hungary
Also repeating my comment from the other thread, could be useful here, should not be lost.
Adding #1144644: Enable specifying the collation when creating a database table → because comment 1 explains to potential root cause perfectly (@catch called my attention to it on Slack).