← Back to team overview

maria-discuss team mailing list archive

Retrieve authentication plugins for user

 

Hi,

When creating an account with multiple authentication plugins, in this case 'unix_socket' OR 'mysql_native_password', the mysql.user.plugin column is set to either one.

How should I retrieve *all* used authentication plugins for a given user?

Example:

```
MariaDB [(none)]> CREATE USER 'testing'@'localhost' IDENTIFIED VIA unix_socket OR mysql_native_password USING 'invalid';
Query OK, 0 rows affected (0.005 sec)

MariaDB [(none)]> select user,host,password,authentication_string,plugin from mysql.user where User = 'testing';
+---------+-----------+----------+-----------------------+-----------------------+
| User    | Host      | Password | authentication_string | plugin                |
+---------+-----------+----------+-----------------------+-----------------------+
| testing | localhost | invalid  | invalid               | mysql_native_password |
+---------+-----------+----------+-----------------------+-----------------------+
1 row in set (0.003 sec)
```

William Edwards


Follow ups