Open
Description
Description
> This function is deprecated in MySQL 5.7 and is removed in MySQL 8.0.
Should we rename it to password
or just remove it?
I found it included by #2680, @XuHuaiyu PTAL
Originally posted by @Defined2014 in #58312 (comment)
The PASSWORD()
function was used in MySQL 5.7 and before to create passwords for mysql_native_password
and sha256_password
. And at some point before MySQL 5.7 it also supported pre-4.1 authentication.
Reasons for removal:
- MySQL 8.0 removes it
- The
PASSWORD()
function doesn't work forcaching_sha2_password
- Using the
PASSWORD()
function to directly update themysql.user
would circumvent password rules. - Using the
PASSWORD()
function to create a hash which then gets used in... IDENTIFIED AS ...
might also circumvent password rules.
This seem to have been deprecated since TiDB version v2.0.0-rc.3
Related
- https://dev.mysql.com/worklog/task/?id=10774
- parser: Fix undocumented password_func function | tidb-test=pr/2458 #58312
- https://dev.mysql.com/doc/refman/5.7/en/encryption-functions.html#function_password
- https://docs.pingcap.com/tidb/stable/security-compatibility-with-mysql#authentication-plugin-status
- expression: Add deprecation warning for builtin function PASSWORD #6000
- select password("xxx") should return a warning #5946
- Remove the PASSWORD() function docs#19731
Activity