old_passwords defaults to 1 in 5.6.12?

Asked by Alfie John

Hi,

I've got a fresh copy of 5.6.12 installed, and found that old_passwords defaults to 1. Is this correct? Looking at the MySQL 5.6 documentation, MySQL defaults to 0.

Also, when doing a GRANT with old_password set to 1 I get:

  "The password hash doesn't have the expected format."

According to the MySQL 5.6 documentation, this error only occurs when an account requires SHA256 passwords (i.e. old_passwords = 2). Since I haven't enabled --default-authentication-plugin=sha256_password, has Percona turned this on by default in 5.6.12?

Question information

Language:
English Edit question
Status:
Answered
For:
Percona Server moved to https://jira.percona.com/projects/PS Edit question
Assignee:
No assignee Edit question
Last query:
Last reply:
Revision history for this message
Alexey Kopytov (akopytov) said :
#1

Alfie,

I don't see anything in the source code that would enable old_passwords by default. Can you paste my.cnf from your installation?

As to the "The password hash doesn't have the expected format." error with old_passwords enabled, it looks like an upstream issue to me. After starting the upstream MySQL 5.6.12 server with old_passwords=1, I also get:

mysql> grant all privileges on test.* to test@localhost identified by 'password';
ERROR 1827 (HY000): The password hash doesn't have the expected format. Check if the correct password algorithm is being used with the PASSWORD() function.

The error doesn't occur with upstream 5.6.10.

Revision history for this message
Alfie John (alfiejohn) said :
#2

Hi Alexey,

I found out what it was and I've filed a bug in upstream - http://bugs.mysql.com/bug.php?id=69889

To summarise:

  - If I login with a pre-4.1.1 password, "SELECT @@old_password" = 1.
  - If I login with a mysql_native_password, "SELECT @@old_password" = 0.
  - If I login with a pre-4.1.1 password, you can't set old_passwords from the config file or command line

Revision history for this message
Alexey Kopytov (akopytov) said :
#3

Alfie,

Thanks for the update.

Can you help with this problem?

Provide an answer of your own, or ask Alfie John for more information if necessary.

To post a message you must log in.