1 頁 (共 1 頁)

[Security]

發表於 : 2020-02-07 17:22:03
schumi
vi /etc/pam.d/sshd
auth required pam_tally2.so deny=3

vi /etc/pam.d/system-auth-ac
password requisite pam_cracklib.so try_first_pass retry=3 minlen=8 dcredit=-1 ucredit=-1 lcredit=-1 difok=3 reject_username
password sufficient pam_unix.so sha512 shadow nullok try_first_pass use_authtok remember=4

vi /etc/login.defs
PASS_MAX_DAYS 90
PASS_MIN_DAYS 1
PASS_MIN_LEN 8
PASS_WARN_AGE 7

修改bash history 紀錄格式
echo 'export HISTTIMEFORMAT="%d/%m/%y %T "' >> ~/.bash_profile ; source ~/.bash_profile