-
Notifications
You must be signed in to change notification settings - Fork 5.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ALTER USER REQUIRE SSL or X509 clears out user's authentication_string (password) #25225
Labels
Comments
Verified against master: CREATE USER u1 IDENTIFIED BY 'acdc';
ALTER USER u1 REQUIRE SSL;
select user,host,authentication_string from mysql.user;
..
mysql> CREATE USER u1 IDENTIFIED BY 'acdc';
Query OK, 0 rows affected (0.04 sec)
mysql> select user,host,authentication_string from mysql.user;
+-------------+------+-------------------------------------------+
| user | host | authentication_string |
+-------------+------+-------------------------------------------+
| root | % | |
| backupadmin | % | |
| u1 | % | *B50FBDB37F1256824274912F2A1CE648082C3F1F |
+-------------+------+-------------------------------------------+
3 rows in set (0.01 sec)
mysql> ALTER USER u1 REQUIRE SSL;
Query OK, 0 rows affected (0.04 sec)
mysql> select user,host,authentication_string from mysql.user;
+-------------+------+-----------------------+
| user | host | authentication_string |
+-------------+------+-----------------------+
| root | % | |
| backupadmin | % | |
| u1 | % | |
+-------------+------+-----------------------+
3 rows in set (0.00 sec)
mysql> SELECT tidb_version()\G
*************************** 1. row ***************************
tidb_version(): Release Version: v5.2.0-alpha-8-gd2c477529
Edition: Community
Git Commit Hash: d2c47752958087c7b7fe229bda4a56af90f5216d
Git Branch: fix-restore-permissions
UTC Build Time: 2021-06-07 20:24:47
GoVersion: go1.16.4
Race Enabled: false
TiKV Min Version: v3.0.0-60965b006877ca7234adaced7890d7b029ed1306
Check Table Before Drop: false
1 row in set (0.00 sec) |
Please edit this comment or add a new comment to complete the following informationNot a bug
Duplicate bug
BugNote: Make Sure that 'component', and 'severity' labels are added 1. Root Cause Analysis (RCA) (optional)2. Symptom (optional)3. All Trigger Conditions (optional)4. Workaround (optional)5. Affected versions6. Fixed versions |
This was referenced Jun 10, 2021
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
Bug Report
Please answer these questions before submitting your issue. Thanks!
1. Minimal reproduce step (Required)
2. What did you expect to see? (Required)
User require SSL or X509 to login
3. What did you see instead (Required)
Yes, SSL or X509 enabled. but user password also set to blank or some value, basically user can no longer login. the password must then be reset.
4. What is your TiDB version? (Required)
Server version: 5.7.25-TiDB-v5.0.0-rc TiDB Server (Apache License 2.0) Community Edition, MySQL 5.7 compatible
The text was updated successfully, but these errors were encountered: