CentOS 8 安裝、架設與使用

audit 工具使用

 

參考資料:
TecMint -- How to Query Audit Logs Using ‘ausearch’ Tool on CentOS/RHEL
https://www.tecmint.com/query-audit-logs-using-ausearch-tool-on-centos-rhel/ 


dnf 指令

dnf repoquery -l pam => 列出 pam 套件檔案

參考資料:
https://tylersguides.com/guides/listing-files-in-a-package-with-dnf/ 


pam_faillock = pam_tally2
/etc/security/faillock.conf
default setting
logfile:audit
deny = 3
unlock_time = 600

參考資料:
https://zhuanlan.zhihu.com/p/127109500 

使用 passwd 修改帳密並設定強度,依流程(passwd -> /etc/pam.d/passwd -> /etc/pam.d/system-auth),應在 system-auth 設定
使用 ssh 登入並限制密碼測試次數,依流程(sshd -> /etc/pam.d/sshd -> /etc/pam.d/password-auth),應在 password-auth 設定


aureport(Authentication Report)
aureport -au -i --failed < 列出

authselect
authselect list

journalctl
journalctl -u sshd < 列出 sshd 的紀錄

參考資料:
redhat 官方文件
https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/8/html-single/configuring_authentication_and_authorization_in_rhel/index#configuring-user-authentication-using-authselect_configuring-authentication-and-authorization-in-rhel

stackexchange 討論
https://serverfault.com/questions/1025907/show-failed-or-bad-ssh-login-attempts-in-centos-8


 

參考資料:
Weithenn 大文章 -- CentOS 8.x 攻略 - 基礎設定系列文章
https://www.weithenn.org/2020/05/centos-8-journey.html

mis 腳印 -- CentOS 8 伺服器作業系統安裝和設定
https://www.footmark.info/linux/centos/centos8-installation/

留言

這個網誌中的熱門文章

zimbra 安裝、管理、設定

Fortigate 100D -- 管理、設定

IT 隨手記6