当前位置:网站首页>How to use fail2ban to protect WordPress login page
How to use fail2ban to protect WordPress login page
2022-07-28 17:01:00 【Brother Xing plays with the clouds】
Fail2Ban scanning /var/log/auth.log Such log files , And forbid IP Address has too many failed login attempts . It updates the system firewall rules to reject those from within a configurable time IP Address to achieve this . Fail2Ban Open the box , You can read many standard log files , for example sshd and Apache The file of , And it can be easily configured to read any log file you choose , To resolve any errors needed .
In this article , I introduced you how to use Fail2Ban Protect SSH service . Now? , I will guide you How to use Fail2Ban Protect WordPress The login page .
To work with WordPress Integrate , You need to WordPress Install in WP fail2ban plug-in unit .
After installation , Need to put WP fail2ban Plug in folder ( Usually located in wordpress/wp-content/plugins/wp-fail2ban) In the folder of wordpress.conf File copy to Fail2ban Folder ( be located /etc/fail2ban/filter.d). And then in /etc/fail2ban/jail.conf Editor in the middle Fail2ban To configure , Add to WordPress part :
[wordpress] enabled = true filter = wordpress logpath = /var/log/auth.log port = http,https maxretry = 5 findtime = 3600 bantime = 86400
This section writes all access errors /var/log/auth.log file , This filter is applicable to http and https. however , If in Web The server Cache agent is used in the configuration of , You also need to be WP fail2ban The plug-in specifies it , So that it begins to get the client address from the special header , instead of Frontend-proxy The address of . So , Please open the wp-config.php file , And add a containing agent The server Configured rows .
define(‘WP_FAIL2BAN_PROXIES’,‘127.0.0.1’); 127.0.0.1 is the address of the proxy server.
Now? , Restart Fail2ban:
service fail2ban restart
边栏推荐
- Interesting kotlin 0x07:composition
- Interesting kotlin 0x06:list minus list
- Exercise note 5 (square of ordered array)
- SUSE Storage6 环境搭建详细步骤 – Win10 + VMware WorkStation
- 有趣的 Kotlin 0x06:List minus list
- Record development issues
- 累计出货130亿颗Flash,4亿颗MCU!深度解析兆易创新的三大产品线
- 【深度学习】:《PyTorch入门到项目实战》第八天:权重衰退(含源码)
- 给定正整数N、M,均介于1~10 ^ 9之间,N <= M,找出两者之间(含N、M)的位数为偶数的数有多少个
- MySQL5.7及SQLyogV12安装及使用破解及常用命令
猜你喜欢

MySQL5.7及SQLyogV12安装及使用破解及常用命令
![[deep learning]: day 1 of pytorch introduction to project practice: data operation and automatic derivation](/img/4e/a41eee56fc0e8d3089f105bcb63155.png)
[deep learning]: day 1 of pytorch introduction to project practice: data operation and automatic derivation

结构化设计的概要与原理--模块化

Re10:读论文 Are we really making much progress? Revisiting, benchmarking, and refining heterogeneous gr
![[deep learning]: the second day of pytorch introduction to project practice: realize linear regression from zero (including detailed code)](/img/19/18d6e94a1e0fa4a75b66cf8cd99595.png)
[deep learning]: the second day of pytorch introduction to project practice: realize linear regression from zero (including detailed code)

Do you really understand CMS garbage collector?

Applet: scroll view slides to the bottom by default

Interesting kotlin 0x0a:fun with composition

小程序:获取元素节点信息

Re13: read the paper gender and racial stereotype detection in legal opinion word embeddings
随机推荐
NoSQL introduction practice notes I
College students participated in six Star Education PHP training and found jobs with salaries far higher than those of their peers
Probability theory and mathematical statistics Chapter 1
MySQL5.7及SQLyogV12安装及使用破解及常用命令
parseJson
SUSE Ceph 增加节点、减少节点、 删除OSD磁盘等操作 – Storage6
向高通支付18亿美元专利费之后,传华为向联发科订购了1.2亿颗芯片!官方回应
做题笔记5(有序数组的平方)
Understanding of asmlinkage
Introduction and implementation of stack (detailed explanation)
Analysis of echo service model in the first six chapters of unp
华为Mate 40系列曝光:大曲率双曲面屏,5nm麒麟1020处理器!还将有天玑1000+的版本
Programmers from entry to roast!!!!
Add differential pairs and connections in Ad
SUSE CEPH add nodes, reduce nodes, delete OSD disks and other operations – storage6
Leetcode learn to insert and sort unordered linked lists (detailed explanation)
小程序:获取元素节点信息
传英伟达已与软银展开会谈,将出价超过320亿美元收购Arm
【深度学习】:《PyTorch入门到项目实战》第四天:从0到1实现logistic回归(附源码)
给定正整数N、M,均介于1~10 ^ 9之间,N <= M,找出两者之间(含N、M)的位数为偶数的数有多少个