1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-29 05:21:33 +03:00

MDEV-10744: Roles are not fully case sensitive

Due to the collation used on the roles_mapping_hash, key comparison
would work in a case-insensitive manner. This is incorrect from the
roles mapping perspective. Make use of a case-sensitive collation for that hash,
the same one used for the acl_roles hash.
This commit is contained in:
Vicențiu Ciorbaru
2016-10-28 17:10:05 +02:00
parent 525e214111
commit e99990c631
3 changed files with 113 additions and 1 deletions

View File

@ -1600,7 +1600,7 @@ my_bool acl_reload(THD *thd)
my_hash_init2(&acl_roles,50, &my_charset_utf8_bin,
0, 0, 0, (my_hash_get_key) acl_role_get_key, 0,
(void (*)(void *))free_acl_role, 0);
my_hash_init2(&acl_roles_mappings, 50, system_charset_info, 0, 0, 0,
my_hash_init2(&acl_roles_mappings, 50, &my_charset_utf8_bin, 0, 0, 0,
(my_hash_get_key) acl_role_map_get_key, 0, 0, 0);
old_mem= acl_memroot;
delete_dynamic(&acl_wild_hosts);