[WordPress] 外掛分享: Fail2WP

首頁 › 外掛目錄 › Fail2WP
WordPress 外掛 Fail2WP 的封面圖片
100+
安裝啟用
★★★★★
5/5 分(2 則評價)
12 天前
最後更新
—
問題解決
WordPress 6.2+ PHP 7.4+ v1.4.0 上架:2021-02-07

內容簡介

Fail2WP 是一款提供安全功能的 WordPress 外掛,並可與 fail2ban 整合。它不需要 fail2ban 即可運作,能有效增強網站的安全性,防止未經授權的登入和其他潛在威脅。

【主要功能】
• 禁用使用者名稱登入,需使用電子郵件
• 允許/拒絕特定 IP 地址或主機名登入
• 防止使用者枚舉攻擊
• 最小使用者名稱長度限制
• 阻止特定使用者名稱註冊新帳戶
• 部分或完全禁用 XMLRPC 存取

外掛標籤

開發者團隊

⬇ 下載最新版 (v1.4.0) 或搜尋安裝

① 下載 ZIP → 後台「外掛 › 安裝外掛 › 上傳外掛」
② 後台搜尋「Fail2WP」→ 直接安裝(推薦)
📦 歷史版本下載

原文外掛簡介

Adds security controls to WordPress.
Fail2ban integration is optional.

Security features:

Disabling login with username (require e-mail address)
Allow/Deny login from IP address, hostname (including wildcard support)
Preventing user enumeration (?author=nnn)
Less detailed error messages on login failures
Minimum username length
Blocking specific usernames from being used to register new users
Requiring e-mail address matching for new user registrations
Warning about new user role setting
Blocking of portions or all of WordPress REST API
Disabling of RSS and Atom feeds
Removal of “Generator” information from HTML and feeds
Detection of Cloudflare IP addresses for logging of actual IP addresses
Blocking/Allowing logins from IP addresses, IP ranges, and/or hostnames
Partially or fully disable XMLRPC access

Monitoring administrator accounts for unexpected role/account changes

Fail2ban can dynamically block IP addresses after suspicious activity.

Other notes:

Requires WordPress 6.2+ and PHP 7.4+.
PHP compatibility checks: 7.4, 8.1, 8.2, 8.3, and 8.4.
Uses mb_ PHP functions when available.
May write to the PHP error log when logging is enabled.
Contains no JavaScript or tracking code.
Optional IP blocking stores IP addresses and security-event timestamps. Administrator monitoring stores administrator IDs and login names.

Reverse proxy configuration:

Available since 1.4.0.
Setting: FAIL2WP_TRUSTED_PROXIES in wp-config.php, before wp-settings.php loads.

Value: array of proxy IPv4/IPv6 addresses or CIDRs.
define( ‘FAIL2WP_TRUSTED_PROXIES’, [ ‘192.0.2.10’, ‘2001:db8:1234::/48’ ] );

Replace the examples with your actual proxy addresses.

List directly connected proxy peers, identified by REMOTE_ADDR.
Hostnames and wildcards: unsupported for this constant.
Undefined or empty array: X-Real-IP ignored.
Accepted header: one valid IP from a listed proxy.
Missing or invalid header: peer address used.
Proxy requirement: overwrite client-supplied X-Real-IP.
Multiple proxy hops: final proxy supplies the verified visitor IP.
X-Forwarded-For and address chains: unsupported.
Proxy trust does not bypass login restrictions or IP bans.
Scope: entire WordPress installation; excluded from settings exports.
Server already supplies a verified REMOTE_ADDR: usually no constant needed.
Cloudflare: enabled setting, matching source range, valid CF-Connecting-IP; takes precedence.
Upgrade: configure trusted proxies before updating an existing X-Real-IP deployment.
Verify client addresses and login access on staging.
Login/bypass hostname wildcards: separate feature; forward-confirmed reverse DNS required.

Credits
The Fail2WP Plugin was written by Joaquim Homrighausen while converting caffeine into code.
Fail2WP is sponsored by WebbPlatsen i Sverige AB, Sweden.
Copyright 2020-2026 Joaquim Homrighausen; all rights reserved.
Commercial support and customizations for this plugin is available from WebbPlatsen i Sverige AB in Sweden.
If you find this plugin useful, the author is happy to receive a donation, good review, or just a kind word.
If there is something you feel to be missing from this plugin, or if you have found a problem with the code or a feature, please do not hesitate to reach out to [email protected].
This plugin can also be downloaded from code.webbplatsen.net and GitHub
More detailed documentation is available at code.webbplatsen.net/documentation/fail2wp/
Kudos to Thomas Lutz.

延伸相關外掛

文章
Filter
Mastodon