Reputation: 2043
When trying to create a new user in phpMyAdmin 4.5.0 on a MariaDB database I get a "1065 - Query was empty" error above the printed query and "The selected user was not found in the privilege table." right on top of the user creation wizard.
Also when I try to edit the query inline, the highlighting complains about an unrecognized statement type "WITH".
The full query as created by phpMyAdmin looks like this:
CREATE USER 'asd'@'%' IDENTIFIED WITH mysql_native_password BY '***';GRANT USAGE ON *.* TO 'asd'@'%' REQUIRE NONE WITH MAX_QUERIES_PER_HOUR 0 MAX_CONNECTIONS_PER_HOUR 0 MAX_UPDATES_PER_HOUR 0 MAX_USER_CONNECTIONS 0;
The syntax highlighting complains about the with in "WITH mysql_native_password" and about the word "USAGE" in the GRANT statement. I don't really know why phpMyAdmin explicitly names the authentication plugin/mechanism when it's using the default and only installed MySQL native password.
When I remove the "WITH mysql_native_password" part from the query it executes just fine. (Obviously I entered the password which was removed/replaced with asterisks by phpMyAdmin in that query again)
So is this authentication plugin stuff a setting I can change somewhere or is this a bug in phpMyAdmin with MariaDB backend?
Thanks in advance.
Upvotes: 3
Views: 4381
Reputation: 111
I think there's a bug in phpMyAdmin... According to MariaDB docs the right way to create an user with mysql_native_password plugin is CREATE USER mysqltest_up1 IDENTIFIED VIA mysql_native_password USING '*E8D46CE25265E545D225A8A6F1BAF642FEBEE5CB';
I haven't found an issue in phpMyAdmin page, so i've opened one: https://github.com/phpmyadmin/phpmyadmin/issues/11520
Docs page: https://mariadb.com/kb/en/mariadb/development-pluggable-authentication/
Upvotes: 4