Keystone does not properly work with Cyrillic symbols in the names of users and projects

Bug #1666395 reported by Anatolii Neliubin
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Mirantis OpenStack
Invalid
Medium
Sergii Rizvan

Bug Description

Detailed bug descriptions:
Keystone does not properly work with entities that contain Cyrillic symbols.
Steps to reproduce:
Create a project and a user with Cyrillic symbols in their names and try getting information about them using OpenStack client.
root@node-4:~# openstack --version
openstack 2.2.0
root@node-4:~# openstack project list
+----------------------------------+-----------------+
| ID | Name |
+----------------------------------+-----------------+
| 28ec4991faf3473281fa91e49973b2dd | тестовый проект |
| 58fbda8b4a9448fab839788a01de1d4d | admin |
| 7606f7402449411b88028ee68d239695 | services |
| 971404618a5a41cfa781ec3a75b69d30 | test project |
+----------------------------------+-----------------+
root@node-4:~# openstack project show "тестовый проект"
No tenant with a name or ID of 'тестовый проект' exists.
root@node-4:~# openstack project show 28ec4991faf3473281fa91e49973b2dd
+-------------+----------------------------------+
| Field | Value |
+-------------+----------------------------------+
| description | описание для тестового проекта |
| enabled | True |
| id | 28ec4991faf3473281fa91e49973b2dd |
| name | тестовый проект |
| properties | |
+-------------+----------------------------------+
root@node-4:~# openstack project show "test project"
+-------------+----------------------------------+
| Field | Value |
+-------------+----------------------------------+
| description | None |
| enabled | True |
| id | 971404618a5a41cfa781ec3a75b69d30 |
| name | test project |
| properties | |
+-------------+----------------------------------+
root@node-4:~# openstack user list
+----------------------------------+-----------------------+
| ID | Name |
+----------------------------------+-----------------------+
| 6df7e27730934dc587a0b322a2bafa7b | admin |
| 4bb08cb7f2fd4e488dd2bcb45270816f | glare |
| 8a54f738fc5a431980d3793322d499b1 | glance |
| 829a3ed118ef4331afd5dc5c0d70d97a | nova |
| bf00a5fbe0ef4d40b1598d8f07ade737 | neutron |
| bfd525b63773418086af21cf132571b7 | cinder |
| c2bc873f4a104351baa87a79a873f58e | heat |
| 4ef354b6b8fa475aa9912827092a977d | heat-cfn |
| 6a08298a84434290bf23f012fe20418c | fuel_stats_user |
| 62f3049fcb924c92b70118b8857f2f73 | тестовый пользователь |
| 6a919aba817b4922849cd4ac7da1fa55 | test user |
| 861e9c1760844dd3886f70a429394d96 | one more test user |
+----------------------------------+-----------------------+
root@node-4:~# openstack user show "тестовый пользователь"
No user with a name or ID of 'тестовый пользователь' exists.
root@node-4:~# openstack user show 62f3049fcb924c92b70118b8857f2f73
+------------+----------------------------------+
| Field | Value |
+------------+----------------------------------+
| email | None |
| enabled | True |
| id | 62f3049fcb924c92b70118b8857f2f73 |
| name | тестовый пользователь |
| project_id | 28ec4991faf3473281fa91e49973b2dd |
| username | тестовый пользователь |
+------------+----------------------------------+
root@node-4:~# openstack user show "test user"
+------------+----------------------------------+
| Field | Value |
+------------+----------------------------------+
| email | None |
| enabled | True |
| id | 6a919aba817b4922849cd4ac7da1fa55 |
| name | test user |
| project_id | 971404618a5a41cfa781ec3a75b69d30 |
| username | test user |
+------------+----------------------------------+
root@node-4:~#

Expected result: There should not be any difference in processing of entities with different code sets.
Workaround: Use ID of users and projects.

Revision history for this message
Margarita Shakhova (shakhova-margarita) wrote :

Anatoly, what locale you use?

Revision history for this message
Margarita Shakhova (shakhova-margarita) wrote :

Is this bug reproduced if LC_ALL is set to utf8 (for some language)?

Revision history for this message
Margarita Shakhova (shakhova-margarita) wrote :

In order to reproduce this bug:
1. use keystone API V2.0
2. use keystone API V3 and non-utf8 locale

Revision history for this message
Vitaly Sedelnik (vsedelnik) wrote :

Anatolii - please specify MOS version, provide steps to reproduce and answer the above questions, thanks!

Changed in mos:
status: New → Incomplete
assignee: nobody → Anatolii Neliubin (aneliubin)
tags: added: area-keystone
Revision history for this message
Anatolii Neliubin (aneliubin) wrote :

Sorry for the delay.
MOS - 9.2
LC_ALL=en_US.UTF-8
LANG=en_US.UTF-8
Steps to reproduce:
root@node-4:~# echo $LANG
en_US.UTF-8
root@node-4:~# echo $LC_ALL
en_US.UTF-8
root@node-4:~# openstack user create "test"
+----------+----------------------------------+
| Field | Value |
+----------+----------------------------------+
| email | None |
| enabled | True |
| id | 9b2d033d095a4f5bbfe6f820bd90f85e |
| name | test |
| username | test |
+----------+----------------------------------+
root@node-4:~# openstack user create "тест"
+----------+----------------------------------+
| Field | Value |
+----------+----------------------------------+
| email | None |
| enabled | True |
| id | 5b74ccf9767e4fd4a1b64fecf54c0390 |
| name | тест |
| username | тест |
+----------+----------------------------------+
root@node-4:~# openstack user show "test"
+----------+----------------------------------+
| Field | Value |
+----------+----------------------------------+
| email | None |
| enabled | True |
| id | 9b2d033d095a4f5bbfe6f820bd90f85e |
| name | test |
| username | test |
+----------+----------------------------------+
root@node-4:~# openstack user show "тест"
No user with a name or ID of 'тест' exists.
root@node-4:~# openstack user show 5b74ccf9767e4fd4a1b64fecf54c0390
+----------+----------------------------------+
| Field | Value |
+----------+----------------------------------+
| email | None |
| enabled | True |
| id | 5b74ccf9767e4fd4a1b64fecf54c0390 |
| name | тест |
| username | тест |
+----------+----------------------------------+
root@node-4:~#

Changed in mos:
status: Incomplete → Confirmed
importance: Undecided → Medium
assignee: Anatolii Neliubin (aneliubin) → MOS Maintenance (mos-maintenance)
milestone: none → 9.x-updates
Sergii Rizvan (srizvan)
Changed in mos:
assignee: MOS Maintenance (mos-maintenance) → Sergii Rizvan (srizvan)
Revision history for this message
Sergii Rizvan (srizvan) wrote :

Upstream code in Mitaka already contains the fix https://github.com/openstack/python-openstackclient/commit/756d2fac67b4128312e1d779648e62f1458b4ffc
This patch was obtained with regular synchronization with upstream and will be released with 9.2-mu2. That's why I'm closing this bug as Invalid.

Changed in mos:
status: Confirmed → Invalid
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.