Bug #78981 [NEW]: Can't connect to MySQL 8 if server's auth plugin does not match user's one

From: Date: Tue, 17 Dec 2019 17:34:03 +0000
Subject: Bug #78981 [NEW]: Can't connect to MySQL 8 if server's auth plugin does not match user's one
Groups: php.bugs 
Request: Send a blank email to php-bugs+get-224362@lists.php.net to get a copy of this message
From: txigreman at hotmail dot com Operating system: Docker php:7.4-fpm image PHP version: 7.4.0 Package: MySQL related Bug Type: Bug Bug description:Can't connect to MySQL 8 if server's auth plugin does not match user's one Description: ------------ I have a MySQL 8 server configured to use caching_sha2_password as default authentication plugin, but it's overrode for a specific user with mysql_native_password. When I try to open a connection to the database, using mysqli or pdo, I get this error: Unexpected server response while doing caching_sha2 auth: 109 It does work if I change the server and/or user configuration to make them match. I think PHP should query the user's authentication plugin instead of using the server's default one. -- Edit bug report at https://bugs.php.net/bug.php?id=78981&edit=1 -- Fix committed: https://bugs.php.net/fix.php?id=78981&r=fixed Fixed in release: https://bugs.php.net/fix.php?id=78981&r=alreadyfixed Need backtrace: https://bugs.php.net/fix.php?id=78981&r=needtrace Need Reproduce Script: https://bugs.php.net/fix.php?id=78981&r=needscript Try newer version: https://bugs.php.net/fix.php?id=78981&r=oldversion Not developer issue: https://bugs.php.net/fix.php?id=78981&r=support Expected behavior: https://bugs.php.net/fix.php?id=78981&r=notwrong Not enough info: https://bugs.php.net/fix.php?id=78981&r=notenoughinfo Submitted twice: https://bugs.php.net/fix.php?id=78981&r=submittedtwice register_globals: https://bugs.php.net/fix.php?id=78981&r=globals PHP version support discontinued: https://bugs.php.net/fix.php?id=78981&r=phptooold Daylight Savings: https://bugs.php.net/fix.php?id=78981&r=dst IIS Stability: https://bugs.php.net/fix.php?id=78981&r=isapi Install GNU Sed: https://bugs.php.net/fix.php?id=78981&r=gnused Floating point limitations: https://bugs.php.net/fix.php?id=78981&r=float No Zend Extensions: https://bugs.php.net/fix.php?id=78981&r=nozend MySQL Configuration Error: https://bugs.php.net/fix.php?id=78981&r=mysqlcfg

« previous php.bugs (#224362) next »