apt-get install fail2ban
プラグイン検索で fail2banを検索 WP-fail2ban をインストール
cp /var/www/wordpress/wp-content/plugins/wp-fail2ban/wordpress.conf /etc/fail2ban/filter.d
cd /etc/fail2ban
cp jail.conf jail.local
vi jail.local
変更
destemail = ckenko25@gmail.com
sendername = Fail2Ban www.ckenko25.com
最終行に追記
[wordpress]
enabled = true
filter = wordpress
logpath = /var/log/auth.log
port = http,https
maxretry = 6
findtime = 86400
bantime = 31536000
/etc/init.d/fail2ban restart
コメント