The largest module, and the one to be most careful with. Every setting here can block a sign-in, including yours.
Read Getting back in before enabling any of it.
Brute-force lockout
| Key | Default |
|---|---|
login_security.bruteforce.enabled | true |
login_security.bruteforce.max_attempts | 5 |
login_security.bruteforce.window_minutes | 15 |
login_security.bruteforce.lockout_minutes | 15 |
Counted per IP and per username, with exponential backoff on repeats.
Per-username matters: an attacker distributing attempts across a botnet defeats per-IP counting entirely, because no single address ever reaches five. Counting the target as well as the source catches the distributed case.
wp itxuo unlock --user=alice
wp itxuo unlock --ip=203.0.113.9
clears one lockout without standing the module down.
IP allow and block lists
| Key | Default |
|---|---|
login_security.ip_allowlist | empty |
login_security.ip_blocklist | empty |
CIDR supported. An allowlist, once non-empty, means only those ranges may sign in.
An allowlist is the fastest way to lock yourself out of your own site. Your address is not as static as you think — mobile networks, home broadband and VPN exits all move. If you set one, set it from the address you are currently using, verify from a second device, and know where ITXUO_DISABLE_LOGIN_SECURITY lives before you close the tab.
Login hours
| Key | Default |
|---|---|
login_security.login_hours | empty |
Per-role windows, timezone-aware. "Editors may sign in 07:00–20:00 in Europe/London."
Useful when it matches a real working pattern, and a nuisance when it does not. It does not end an existing session at the boundary; it prevents a new sign-in.
Country rules
| Key | Default |
|---|---|
login_security.country_mode | block |
login_security.country_list | empty |
login_security.geo.mmdb_path | empty |
Backed by a local GeoLite2 database that you supply the path to. No lookup service, no outbound request, no per-request latency to somebody else's API.
If no database is configured, country rules cannot evaluate and do not block. That is the safe direction — a missing geo database must never mean "block everyone".
Bot defence
| Key | Default |
|---|---|
login_security.bot_defense | true |
Catches the automated form submissions that make up most login noise. No CAPTCHA, no third-party script, nothing for a real person to solve.
Generic error messages
| Key | Default |
|---|---|
login_security.hardening.generic_errors | true |
WordPress by default says "unknown username" or "the password you entered for the username *alice* is incorrect" — which confirms whether an account exists. This replaces both with one message that reveals nothing.
Adaptive step-up
| Key | Default |
|---|---|
risk.enabled | false |
risk.remember_days | 180 |
risk.exempt_roles | empty |
Scores a sign-in against what is normal for that account — new device, new country, unusual hour — and asks for a second factor when it looks unfamiliar, rather than on every login.
Recognised devices are remembered for risk.remember_days. A passkey login suppresses step-up, because it is already stronger.
New-device alerts
| Key | Default |
|---|---|
login_security.alerts.new_device | true |
login_security.alerts.scope | all |
Notifies on a sign-in from a device the account has not used before. Scope can be narrowed to particular roles or groups.
Enumeration hardening
Stops WordPress volunteering the list of your usernames:
| Key | Default | Blocks |
|---|---|---|
enum.rest_users | off | /wp-json/wp/v2/users |
enum.author_query | false | /?author=1 redirects |
enum.oembed_author | false | Author name in oEmbed responses |
enum.user_sitemap | false | The author sitemap |
enum.illegal_logins | false | Registration of reserved usernames |
Each is off by default because each can break something legitimate — a headless front end reads /wp-json/wp/v2/users, and an author sitemap is sometimes wanted.
XML-RPC
| Key | Default |
|---|---|
xmlrpc.mode | off |
xmlrpc.allowed_methods | empty |
xmlrpc.disable_multicall | false |
system.multicall is the one worth knowing about: it lets an attacker attempt hundreds of passwords in a single HTTP request, which is how XML-RPC brute-force gets past naive rate limiting.
Application passwords
The IP, country, lockout and hours rules can be extended to the application-password channel — see Application passwords, where those switches live.
Every block raises an event
Each of these dispatches a severity: warning event, so an alert rule can notify on it with no extra wiring, and the log records what blocked what.
The kill switch
define( 'ITXUO_DISABLE_LOGIN_SECURITY', true );
Turns off IP rules, geo blocking, lockouts, login hours, bot defence and adaptive step-up — all of it, to fix any one of them, and it stays off until somebody edits wp-config.php again.
That bluntness is why the WP-CLI commands exist. Prefer them.