Learn

When something goes wrong

The wafctl command-line tool works on the gateway's machine even when the admin UI is unreachable or you are locked out. Run it as Administrator on Windows or with sudo on Linux.

Problem What to do
A rule blocks you or your visitors Disable the rule in the admin UI (the admin UI is never subject to rules). Or restore the previous version under Configuration History. From the command line: wafctl rules disable-all or wafctl mode detection-only (then wafctl mode enforce to switch back).
A change broke the site Configuration History → open the last good version → Restore. Or from the command line: wafctl config restore-last-good
Badge "Unavailable: public traffic is refused" Hover over the badge for the reason. Restore a working version. Public traffic stays refused (503) until the firewall works again — that is deliberate.
Forgot the password / locked out Run wafctl admin reset-password on the machine. It sets a new password, unlocks the account and ends all sessions. A lockout also ends by itself after 15 minutes.
Lost the phone with the authenticator app Sign in with a recovery code (after the password, choose Use a recovery code). Or run wafctl admin reset-2fa on the machine.
Locked out of remote access wafctl admin unregister-url turns off remote access. wafctl admin allow-ip <address> adds your address to the allowlist.
The service does not start Check the service log (Windows Event Log or journalctl -u wafgateway -n 50). The most common cause is another program on port 80 or 443. The installer names it.
Let's Encrypt fails Check that the host name points to the gateway and port 80 is reachable from the internet. The reason is on the Certificates page. Click Request certificates now.
Visitors see "This site is temporarily unavailable" No backend of the route answered. Check the dashboard (errors per route) and the request log (Server errors (5xx)): each entry shows the reason and the backend tried. Check that the backend machine and service are running.
A route is "On failover" None of the primary backends is healthy. The request log shows which backend served each request. Traffic returns automatically 30 seconds after the primary is healthy again.
A legitimate request is blocked Open it in the request log → Allow this here (attack detection) or Allow this (false positive) (a rule). See Handling a false positive.

Useful wafctl commands

wafctl status                           # data folder, active config, admin accounts, remote access
wafctl config history                   # list configuration versions
wafctl config restore-last-good         # restore the last valid configuration
wafctl mode detection-only              # stop all blocking (allow everything)
wafctl mode enforce                     # resume blocking
wafctl rules disable-all                # disable all rules
wafctl admin list                       # list admin users
wafctl admin add --user <name>          # create a new administrator
wafctl admin reset-password             # reset a password and unlock the account
wafctl admin reset-2fa                  # reset two-factor sign-in
wafctl admin unregister-url             # turn off remote access
wafctl bans list                        # list banned addresses
wafctl bans remove <address>            # unban an address
wafctl ha promote                       # promote this standby to primary
wafctl signatures status                # show the installed signature pack
wafctl signatures rollback              # roll back to the previous pack

Run all commands as Administrator (Windows) or with sudo (Linux). A running gateway applies changes within seconds.