SHOW VARIABLES LIKE 'mandatory_roles';
SET GLOBAL mandatory_roles = 'role_manager';
FLUSH PRIVILEGES;
SHOW VARIABLES LIKE 'activate_all_roles_on_login';
SET GLOBAL activate_all_roles_on_login = ON;
FLUSH PRIVILEGES;
show global variables like 'default_password_lifetime';
set persist default_password_lifetime = 180;
flush PRIVILEGES;
SELECT
host,user
FROM
mysql.user
WHERE
host = 'host'
AND (Password_reuse_history <> 5
OR password_lifetime <> 180
OR user_attributes IS NULL)
ALTER USER 'some.user'@'host'
IDENTIFIED WITH mysql_native_password BY 'new_password'
PASSWORD EXPIRE INTERVAL 180 DAY
FAILED_LOGIN_ATTEMPTS 5 PASSWORD_LOCK_TIME 2
PASSWORD HISTORY 5;
SHOW VARIABLES LIKE 'mandatory_roles';
SET GLOBAL mandatory_roles = 'role_manager';
FLUSH PRIVILEGES;
SHOW VARIABLES LIKE 'activate_all_roles_on_login';
SET GLOBAL activate_all_roles_on_login = ON;
FLUSH PRIVILEGES;
show global variables like 'default_password_lifetime';
set persist default_password_lifetime = 180;
flush PRIVILEGES;
SELECT
host,user
FROM
mysql.user
WHERE
host = 'host'
AND (Password_reuse_history <> 5
OR password_lifetime <> 180
OR user_attributes IS NULL)
ALTER USER 'some.user'@'host'
IDENTIFIED WITH mysql_native_password BY 'new_password'
PASSWORD EXPIRE INTERVAL 180 DAY
FAILED_LOGIN_ATTEMPTS 5 PASSWORD_LOCK_TIME 2
PASSWORD HISTORY 5;
SHOW VARIABLES LIKE 'mandatory_roles';
SET GLOBAL mandatory_roles = 'role_manager';
FLUSH PRIVILEGES;
SHOW VARIABLES LIKE 'activate_all_roles_on_login';
SET GLOBAL activate_all_roles_on_login = ON;
FLUSH PRIVILEGES;
show global variables like 'default_password_lifetime';
set persist default_password_lifetime = 180;
flush PRIVILEGES;
SELECT
host,user
FROM
mysql.user
WHERE
host = 'host'
AND (Password_reuse_history <> 5
OR password_lifetime <> 180
OR user_attributes IS NULL)
ALTER USER 'some.user'@'host'
IDENTIFIED WITH mysql_native_password BY 'new_password'
PASSWORD EXPIRE INTERVAL 180 DAY
FAILED_LOGIN_ATTEMPTS 5 PASSWORD_LOCK_TIME 2
PASSWORD HISTORY 5;
SHOW VARIABLES LIKE 'mandatory_roles';
SET GLOBAL mandatory_roles = 'role_manager';
FLUSH PRIVILEGES;
SHOW VARIABLES LIKE 'activate_all_roles_on_login';
SET GLOBAL activate_all_roles_on_login = ON;
FLUSH PRIVILEGES;
show global variables like 'default_password_lifetime';
set persist default_password_lifetime = 180;
flush PRIVILEGES;
SELECT
host,user
FROM
mysql.user
WHERE
host = 'host'
AND (Password_reuse_history <> 5
OR password_lifetime <> 180
OR user_attributes IS NULL)
ALTER USER 'some.user'@'host'
IDENTIFIED WITH mysql_native_password BY 'new_password'
PASSWORD EXPIRE INTERVAL 180 DAY
FAILED_LOGIN_ATTEMPTS 5 PASSWORD_LOCK_TIME 2
PASSWORD HISTORY 5;
SHOW VARIABLES LIKE 'mandatory_roles';
SET GLOBAL mandatory_roles = 'role_manager';
FLUSH PRIVILEGES;
SHOW VARIABLES LIKE 'activate_all_roles_on_login';
SET GLOBAL activate_all_roles_on_login = ON;
FLUSH PRIVILEGES;
show global variables like 'default_password_lifetime';
set persist default_password_lifetime = 180;
flush PRIVILEGES;
SELECT
host,user
FROM
mysql.user
WHERE
host = 'host'
AND (Password_reuse_history <> 5
OR password_lifetime <> 180
OR user_attributes IS NULL)
ALTER USER 'some.user'@'host'
IDENTIFIED WITH mysql_native_password BY 'new_password'
PASSWORD EXPIRE INTERVAL 180 DAY
FAILED_LOGIN_ATTEMPTS 5 PASSWORD_LOCK_TIME 2
PASSWORD HISTORY 5;
SHOW VARIABLES LIKE 'mandatory_roles';
SET GLOBAL mandatory_roles = 'role_manager';
FLUSH PRIVILEGES;
SHOW VARIABLES LIKE 'activate_all_roles_on_login';
SET GLOBAL activate_all_roles_on_login = ON;
FLUSH PRIVILEGES;
show global variables like 'default_password_lifetime';
set persist default_password_lifetime = 180;
flush PRIVILEGES;
SELECT
host,user
FROM
mysql.user
WHERE
host = 'host'
AND (Password_reuse_history <> 5
OR password_lifetime <> 180
OR user_attributes IS NULL)
ALTER USER 'some.user'@'host'
IDENTIFIED WITH mysql_native_password BY 'new_password'
PASSWORD EXPIRE INTERVAL 180 DAY
FAILED_LOGIN_ATTEMPTS 5 PASSWORD_LOCK_TIME 2
PASSWORD HISTORY 5;
SHOW VARIABLES LIKE 'mandatory_roles';
SET GLOBAL mandatory_roles = 'role_manager';
FLUSH PRIVILEGES;
SHOW VARIABLES LIKE 'activate_all_roles_on_login';
SET GLOBAL activate_all_roles_on_login = ON;
FLUSH PRIVILEGES;
show global variables like 'default_password_lifetime';
set persist default_password_lifetime = 180;
flush PRIVILEGES;
SELECT
host,user
FROM
mysql.user
WHERE
host = 'host'
AND (Password_reuse_history <> 5
OR password_lifetime <> 180
OR user_attributes IS NULL)
ALTER USER 'some.user'@'host'
IDENTIFIED WITH mysql_native_password BY 'new_password'
PASSWORD EXPIRE INTERVAL 180 DAY
FAILED_LOGIN_ATTEMPTS 5 PASSWORD_LOCK_TIME 2
PASSWORD HISTORY 5;
SHOW VARIABLES LIKE 'mandatory_roles';
SET GLOBAL mandatory_roles = 'role_manager';
FLUSH PRIVILEGES;
SHOW VARIABLES LIKE 'activate_all_roles_on_login';
SET GLOBAL activate_all_roles_on_login = ON;
FLUSH PRIVILEGES;
show global variables like 'default_password_lifetime';
set persist default_password_lifetime = 180;
flush PRIVILEGES;
SELECT
host,user
FROM
mysql.user
WHERE
host = 'host'
AND (Password_reuse_history <> 5
OR password_lifetime <> 180
OR user_attributes IS NULL)
ALTER USER 'some.user'@'host'
IDENTIFIED WITH mysql_native_password BY 'new_password'
PASSWORD EXPIRE INTERVAL 180 DAY
FAILED_LOGIN_ATTEMPTS 5 PASSWORD_LOCK_TIME 2
PASSWORD HISTORY 5;
SHOW VARIABLES LIKE 'mandatory_roles';
SET GLOBAL mandatory_roles = 'role_manager';
FLUSH PRIVILEGES;
SHOW VARIABLES LIKE 'activate_all_roles_on_login';
SET GLOBAL activate_all_roles_on_login = ON;
FLUSH PRIVILEGES;
show global variables like 'default_password_lifetime';
set persist default_password_lifetime = 180;
flush PRIVILEGES;