等保MySQL数据库检查项命令

916 阅读1分钟

前言

本篇文章总结了等级保护测评中MySQL数据库所有检查项的命令,供大家学习使用!!!

正文

1、身份认证插件

show variables like 'default_authentication%';

2、查看版本

select version();

3、查看身份鉴别信息及插件(5.7以上的版本)

select host,user,authentication_string,plugin from mysql.user;(5.7以上的版本)

4、是否安装口令复杂度检验模块(5.7以上的版本)

select * from information_schema.plugins where plugin_name='validate_password';

5、查看口令复杂度策略(5.7以上的版本)

show variables like 'validate_password%';

6、查看定期更换策略(5.7以上的版本)

select host,user,password_lifetime from mysql.user;

7、查看链接超时时间

show global variables like '%timeout';

8、查看登录失败功能是否安装

select * from information_schema.plugins where plugin_name='connection_control';

9、查看登陆失败参数

show variables like 'connection_control%';

10、查看各账户权限

select * from mysql.user; select * from mysql.db; select * from mysql.tables_priv; select * from mysql.columns_priv;

11、查看数据库日志模块

show variables like 'general_log%'; set global general_log=on;(开启日志)

12、查看ssl参数

show variables like '%ssl%';

13、是否开启了强制ssl、tls通信

show variables like 'require_secure_transport';

总结

后续会持续给大家更新!!!!

更多分享微信搜索“安全info”公众号
添加群主(微信号:h1247517428)进“安全交流”微信群