Strangely, this worked fine for a while, but my computer rebooted recently and now my php apps won't work:
mysqlnd cannot connect to MySQL 4.1+ using the old insecure authentication. Please use an administration tool to reset your password with the command SET PASSWORD = PASSWORD('your_existing_password'). This will store a new, and more secure, hash value in mysql.user. If this user is used in other scripts executed by PHP 5.2 or earlier you might need to remove the old-passwords flag from your my.cnf file [2000]
I saw the solution was to turn off old_passwords in the mysql config... except it wasn't turned on in my my.cfg (the option wasn't present at all and adding it changed nothing) nor will it change in the console:.
> SET SESSION old_passwords=FALSE;
ERROR 1231 (42000): Variable 'old_passwords' can't be set to the value of '0'
I tried looking at the password hash:
> select password('test');
+------------------+
| password('test') |
+------------------+
| 378b243e220ca493 |
+------------------+
And it is short. There's nothing I can find on the net as to why it does that, the mariadb docs say it is supposed to be 41 characters long, but it just isn't and it is breaking all the php 5.4 stuff.
I'm out of ideas short of just saying forget it and reinstalling an old php or something. Anyone else seen this? Ideally, I'd like the passwords to use the new hash format so php just works.