[MXS-1693] In Maxscale 2.2.2 getting users with native password from mysql backends does not work Created: 2018-03-01  Updated: 2019-05-22  Resolved: 2018-03-05

Status: Closed
Project: MariaDB MaxScale
Component/s: Authenticator
Affects Version/s: 2.2.2
Fix Version/s: 2.2.3

Type: Bug Priority: Major
Reporter: Goran Assignee: markus makela
Resolution: Fixed Votes: 1
Labels: authentication
Environment:

Ubuntu 16.04 with latest Maxscale 2.2.2


Issue Links:
Problem/Incident
is caused by MXS-1627 MySQLAuth loads users that use authen... Closed
Relates
relates to MXS-1769 Since Maxscale 2.2.2 getting users fr... Closed
relates to MXS-2494 MySQLAuth load users query doesn't ch... Closed

 Description   

Hi,

In Maxscale 2.2.2 getting users with native password from mysql backends does not work. As you can see here: https://github.com/mariadb-corporation/MaxScale/blob/2.2.2/server/modules/authenticator/MySQLAuth/dbusers.c new query for getting users (for Mysql > 5.7) is

SELECT u.user, u.host, d.db, u.select_priv, u.authentication_string
    FROM mysql.user AS u LEFT JOIN mysql.db AS d
    ON (u.user = d.user AND u.host = d.host) WHERE u.plugin = ''
    UNION
    SELECT u.user, u.host, t.db, u.select_priv, u.authentication_string
    FROM mysql.user AS u LEFT JOIN mysql.tables_priv AS t
    ON (u.user = t.user AND u.host = t.host) WHERE u.plugin = '';

This part is added (this was not in 2.1.x versions): WHERE u.plugin = ''

And in my user.plugin column all users have 'mysql_native_password' value, so maxscale does not get them and 'maxadmin show dbusers <service-name>' is always empty so my clients can't connect to DB through maxscale.



 Comments   
Comment by markus makela [ 2018-03-05 ]

Fixed in f066ba8753eada1c7aa720f14e00025b049d4899.

Generated at Thu Feb 08 04:08:42 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.