Aller au contenu

Path & Access Control Bypass

Ce contenu n’est pas encore disponible dans votre langue.

Check IDTitleCVSS 4.0CWEOWASP
accesscontrol.path_bypassAccess Control Bypassed via Path Normalization8.7CWE-284API5:2023
accesscontrol.method_bypassAccess Control Bypassed via HTTP Method8.7CWE-650API5:2023
accesscontrol.nginx_alias_traversalNginx Off-by-Slash Alias Traversal8.7CWE-22API8:2023

Probes a fixed list of common protected paths (/admin, /internal, /private). For any that deny a plain GET, it retries case/encoding/traversal variants of the same path — uppercase, a duplicate leading slash, a trailing slash or dot segment, a partially percent-encoded traversal back to itself, a double-encoded first byte, a trailing null byte, and a matrix (;) parameter — that a backend commonly normalizes away before routing. A variant that succeeds where the plain path was denied means the access control is matching on the raw, unnormalized path instead of the path the backend will actually resolve.

Remediate: decode and canonicalize the path (case-fold, resolve ./.. segments, collapse duplicate slashes, strip matrix parameters) using the same logic the backend router uses, before making the access-control decision — ideally by enforcing the check at the same layer that does the routing, rather than in front of it.

Probes the same fixed list of common protected paths and, for any that deny a GET, retries the identical path with HEAD, POST, PUT, PATCH, DELETE, and OPTIONS. A verb that succeeds where GET was denied means the access control only gates the verb it expects instead of every verb the backend routes to that handler.

Remediate: apply the access-control check independent of the HTTP method, or deny by default and explicitly allow only the methods a path is meant to support.

Skipped for targets that don’t fingerprint as nginx via the Server header. For a fixed list of common alias-style location prefixes (/files, /static, /assets, /media, /public, /uploads, /download), fetches <prefix>/index.html and, if that returns 200, also fetches <prefix>index.html — the same filename appended directly onto the prefix with no / separator. Identical content on both means the location matching that prefix has no trailing slash, so nginx strips only the literal prefix and appends the remainder of the request path verbatim to the alias directory — from there, an attacker can substitute a ../ traversal for the filename to escape the aliased directory entirely (the classic Gixy alias_traversal finding).

Remediate: add a trailing slash to the location (e.g. location /files/ { alias ...; }), or use root instead of alias when the location and filesystem paths are meant to line up.