The Password Reuse Check Plugin prevents users from reusing previous passwords, with a retention policy controlled by the password_reuse_check_interval variable.
The plugin is used to prevent a user from reusing a password, which can be a requirement in some security policies. The system variable determines the retention period, in days, for a password. By default, this is zero, meaning unlimited retention. Old passwords are stored in the .
Note that passwords can be directly set as a hash, bypassing the password validation, if the variable is OFF (it is ON by default).
Although the plugin's shared library is distributed with MariaDB by default, the plugin is not actually installed by MariaDB by default.
You can install the plugin dynamically, without restarting the server, by executing or :
The second method can be used to tell the server to load the plugin when it starts up. The plugin can be installed this way by providing the or the options. This can be specified as a command-line argument to or it can be specified in a relevant server in an :
You can uninstall the plugin dynamically by executing or :
If you installed the plugin by providing the or the options in a relevant server in an , then those options should be removed to prevent the plugin from being loaded the next time the server is restarted.
The bump to version 2.0 required the change of the stored format to mitigate an implementation weakness () and as such the bump from 1.0 to 2.0 will invalidate previously saved password reuse protections.
(MariaDB Foundation blog post)
This page is licensed: CC BY-SA / Gnu FDL
1.0
Alpha
1.0
Beta
1.0
Gamma
2.0
Stable
, , ,
INSTALL SONAME 'password_reuse_check';[mariadb]
...
plugin_load_add = password_reuse_checkUNINSTALL SONAME 'password_reuse_check';INSTALL SONAME 'password_reuse_check';
GRANT SELECT ON *.* TO user1@localhost identified by 'pwd1';
Query OK, 0 rows affected (0.038 sec)
GRANT SELECT ON *.* TO user1@localhost identified by 'pwd1';
ERROR 1819 (HY000): Your password does not satisfy the current policy requirements
GRANT SELECT ON *.* TO user1@localhost identified by 'pwd2';
Query OK, 0 rows affected (0.003 sec)
GRANT SELECT ON *.* TO user1@localhost identified by 'pwd1';
ERROR 1819 (HY000): Your password does not satisfy the current policy requirements