Skip to content

WAF (Web Application Firewall)

A web application firewall: a filter that stands in front of a site and blocks suspicious requests. It protects from attacks but sometimes also blocks legitimate calls.

How It Works

Each incoming request is checked against rules: headers, User-Agent, frequency of requests, suspicious patterns. What doesn’t pass is discarded.

Typical Problem

WAF may block a correct request if it doesn’t like the form:

  • The Authorization header is blocked, while the same token in the URL is allowed;
  • curl and python-requests are blocked by User-Agent, while the browser header passes.

So a 403 from the API often means not an authorization error but a filtering rule from the hosting.

How to Distinguish from API Error

  • API Error — response 200 with JSON like `{