79% vs 51%: independent neobanks lag on app security. Read the report

Deep Dive

Deep Dive

Pangolin Path Rule Auth Bypass via Encoded Slashes (CVE-2026-136132)

Pangolin before 1.21.0 matches path bypass rules on raw segments, so /public/../admin/ skips authentication; fixed in 1.21.0.

TL;DR

  • isPathAllowed() matches a request path to Bypass Auth rules without resolving .. segments or encoded slashes, so /public/../admin/ satisfies a public/* rule and skips authentication. The Pangolin repository published advisory GHSA-5h3v-3645-78xj on 2026-11-19.
  • Every self-hosted release before 1.21.0 is affected when a resource requires authentication and has a wildcard path rule set to Bypass Auth. The backend must also normalize dot segments, as Nginx, Node.js and most file servers do.
  • The CVE record rates CVE-2026-136132 at CVSS v4.0 9.2 Critical and CVSS v3.1 8.6 High. No exploitation is known and the CVE is not in CISA KEV as of 2026-11-24.
  • Upgrade to Pangolin 1.21.0 or later, which carries commit 9561d23f1e77. See "How do I fix it?" for interim rule changes.

Am I affected?

A Pangolin deployment is exposed when all of these conditions hold:

  • The server runs a release before 1.21.0, in the Community or the Enterprise Edition.
  • At least one resource has authentication enabled and a path-based rule whose action is Bypass Auth.
  • That rule's pattern contains a wildcard, so it can match more segments than the operator listed.
  • A protected path on the same resource can be reached from the bypassed prefix with .. segments or an encoded slash.
  • The backend normalizes .. or decodes %2F before it routes the request.

A bypass rule for public/* is the common case. The pattern matches the first segment public and lets the single * stand in for every later segment. Nothing in the matcher resolves . or .., so the wildcard also stands in for ... A request for /public/../admin/ therefore matches the public rule, while the application behind Pangolin receives /admin/.

The shipped Traefik configuration makes the encoded form practical. config/traefik/traefik_config.yml sets encodedCharacters.allowEncodedSlash: true, so Traefik accepts %2F inside a path instead of rejecting it. Many backends decode that sequence before routing, and the request reaches the protected directory.

Branch Affected versions Fixed version
Community Edition All releases before 1.21.0 1.21.0 or later
Enterprise Edition All releases before 1.21.0 1.21.0 or later

Both editions run the same server code in server/, so the fix in server/lib/pathMatch.ts covers both. The project is widely deployed: the Pangolin repository has 23,973 stars, and the fosrl/pangolin image has 7,104,724 pulls on Docker Hub (checked 2026-11-24).

Check the server version from the OCI label on the running container:

docker inspect --format '{{index .Config.Labels "org.opencontainers.image.version"}}' pangolin

The same version is shown in the Pangolin dashboard. List the local images when the container name differs:

docker image ls fosrl/pangolin

Find resources with path rules in the dashboard under Resources, then the Rules tab of each resource. A rule that matters here has match type Path, an action of Bypass Auth, and a value that ends in *.

How do I fix it?

Upgrade the server to 1.21.0 or later. The current release is 1.27.1, published on 2026-11-20. The fix is commit 9561d23f1e77 in server/lib/pathMatch.ts.

  1. Back up config/config.yml and the database, then pull the new image and recreate the container:
cd /path/to/pangolin
docker compose pull
docker compose up -d
  1. Confirm the running container reports 1.21.0 or later:
docker inspect --format '{{index .Config.Labels "org.opencontainers.image.version"}}' pangolin
  1. If the deployment pins an image tag in docker-compose.yml, change it to 1.21.0 or a later tag. Pulling a new image does not update a container that was created from an older one, so the container must be recreated.

If you cannot upgrade yet, remove every wildcard Bypass Auth rule and replace it with exact paths, or require authentication on those paths. An exact path such as public/logo.png does not contain a wildcard, so .. cannot be absorbed by it.

A second interim control is to reject traversal at the edge. Add a rule in the proxy in front of Pangolin that refuses request paths containing %2f, %2e or ... This blocks the demonstrated requests, but it does not repair the matcher. Encoded variants and unusual clients can still reach the same code path, and the filter can break legitimate URLs that contain a dot segment.

What is the root cause?

isPathAllowed() compares a rule pattern with a request path by splitting both on / and matching the resulting segments in order. It never decodes percent escapes inside a segment and never resolves . or .., so a traversal is just a segment name to the matcher.

The vulnerable function is short. This is the version at commit 113b7a0, the revision the CVE record cites:

export function isPathAllowed(pattern: string, path: string): boolean {
    const normalize = (p: string) => p.split("/").filter(Boolean);
    const patternParts = normalize(pattern);
    const pathParts = normalize(path);

    function matchSegments(
        patternIndex: number,
        pathIndex: number,
        depth: number = 0
    ): boolean {
        if (depth > MAX_RECURSION_DEPTH) {
            return false;
        }

        const currentPatternPart = patternParts[patternIndex];
        const currentPathPart = pathParts[pathIndex];

        if (patternIndex >= patternParts.length) {
            return pathIndex >= pathParts.length;
        }

        if (pathIndex >= pathParts.length) {
            return patternParts.slice(patternIndex).every((p) => p === "*");
        }

        if (currentPatternPart === "*") {
            if (matchSegments(patternIndex + 1, pathIndex, depth + 1)) {
                return true;
            }
            if (matchSegments(patternIndex, pathIndex + 1, depth + 1)) {
                return true;
            }
            return false;
        }

The currentPatternPart === "*" branch handles the wildcard. With a pattern of public/*, the first call compares public with the first path segment. When they are equal, the next call sees * and tries two branches. One branch ends the pattern, and the other consumes one more path segment and calls itself again. The wildcard can therefore consume any number of segments, including .., and the match succeeds for /public/../admin/.

isPathAllowed() is called from verifyResourceSession() in server/routers/badger/verifySession.ts, which evaluates the rules attached to a resource. When a path rule matches, its action is returned before the authentication checks run. A Bypass Auth action therefore ends the decision as "allow", and the proxy forwards the request.

The other half of the problem is the proxy configuration. Pangolin ships Traefik with allowEncodedSlash: true:

      encodedCharacters:
        allowEncodedSlash: true
        allowEncodedQuestionMark: true

That setting lets a request such as /public%2F..%2Fadmin/ through the proxy instead of rejecting it as malformed. Different layers normalize it differently. Pangolin's matcher may see one segment or a segment containing .., while the backend decodes %2F and resolves the dot segments. The two layers disagree about the path, and the access decision is made on the layer that does not resolve it.

How is it exploited?

An attacker needs a resource with a wildcard bypass rule and a backend that resolves the path. The advisory's reproduction uses a resource with authentication enabled and one Bypass Auth rule for public/*, proxied to a server with /public/ and /admin/ directories.

  1. Request the public path and record the control response. The advisory shows /public/ returning the public page with HTTP 200.
  2. Request the protected path directly and confirm it is protected. The same setup returns a redirect to the Pangolin login, HTTP 302.
  3. Send the traversal with encoded slashes so the client does not normalize it before sending:
curl -k https://pangolin.example/public%2F..%2Fadmin/
  1. Pangolin matches the request against public/* because the matcher does not resolve .. or the encoded slash. The Bypass Auth action applies and no login is required.
  2. Traefik forwards the request. The backend decodes the slashes and resolves the parent segment, so it serves /admin/. The advisory records HTTP 200 and the admin page body.

The encoded form avoids client-side normalization. A client that sends /public/../admin/ literally can be made to do so with curl --path-as-is, and the same result follows when the matcher receives the undecoded dots. The advisory states that its request returned the admin content, and it lists the control responses for the public and protected paths.

How does the attack flow?

The attack is one request: the path matcher accepts the public prefix, the bypass rule fires, and the backend resolves the traversal to the protected path.

flowchart LR A["GET /public%2F..%2Fadmin/"] --> B["isPathAllowed() splits on /"] B --> C[".. matches the wildcard: no normalization"] C --> D["Bypass Auth rule applies"] D --> E["Traefik forwards the request"] E --> F["Backend resolves .. and serves /admin/"]

What can an attacker do?

An unauthenticated attacker can read content on protected paths of a resource that carries a wildcard Bypass Auth rule. That content can include administration pages, dashboards, internal APIs and files served by the backend. The CVE record scores confidentiality as High and integrity and availability as None, so the demonstrated impact is disclosure, not modification.

The conditions are specific, and each one matters:

  • A path rule with the Bypass Auth action must exist on the resource. A resource with no rules, or with only exact-path rules, is not exposed.
  • The rule's pattern must contain a wildcard that can absorb the traversal segments.
  • The backend must normalize the path before routing. A backend that returns the raw path as a 404 does not expose the protected file.
  • The protected content must sit under the same resource and host as the bypassed prefix. The bypass does not cross to another resource or another host.

The advisory reports that the same result held on a self-hosted Enterprise Edition at 1.20.0. It does not report exploitation in the wild, and none is known as of 2026-11-24.

Why does the fix work?

The fix normalizes the request path before matching. decodeAndResolvePath() decodes each raw segment with decodeURIComponent(), splits any slash that the decoding produces, drops . segments and pops the previous segment for ... The matcher then compares the resolved path with the rule pattern, so a traversal cannot satisfy a public prefix.

+function decodeAndResolvePath(p: string): string[] {
+    const rawParts = p.split("/").filter(Boolean);
+
+    const resolved: string[] = [];
+    for (const rawPart of rawParts) {
+        let part: string;
+        try {
+            part = decodeURIComponent(rawPart);
+        } catch {
+            part = rawPart;
+        }
+
+        // an encoded slash can turn one raw segment into several real ones
+        for (const segment of part.split("/").filter(Boolean)) {
+            if (segment === ".") {
+                continue;
+            } else if (segment === "..") {
+                resolved.pop();
+            } else {
+                resolved.push(segment);
+            }
+        }
+    }
+
+    return resolved;
+}
+
 export function isPathAllowed(pattern: string, path: string): boolean {
-    const normalize = (p: string) => p.split("/").filter(Boolean);
-    const patternParts = normalize(pattern);
-    const pathParts = normalize(path);
+    const patternParts = pattern.split("/").filter(Boolean);
+    const pathParts = decodeAndResolvePath(path);

The patch adds six regression checks in server/routers/badger/verifySession.test.ts. They require isPathAllowed("public/*", "public/../admin") and isPathAllowed("public/*", "public%2F..%2Fadmin") to return false. They also require a traversal into a restricted path to be caught by that path's own rule, and an encoded slash without traversal to keep matching normally.

The fix is complete for this bypass in the paths the advisory covers. The rule pattern is still administrator input and is not decoded, so a pattern that itself contains encoded characters is compared as written. That does not create a traversal, because the request path is resolved before the comparison.

How do I check if I was compromised?

No indicators of compromise are published for this issue. A successful request looks like ordinary traffic to the backend, and Pangolin may record only the decision it made.

Check the access records for requests that combine a public prefix with an encoded separator or a parent segment. Request paths containing %2F, %2f, %2E, %2e or .. are the pattern to look for. A hit is a lead, not proof: some legitimate URLs contain encoded characters.

grep -Ei '(%2f|%2e|\.\.)' /var/log/traefik/access.log

In the Pangolin dashboard, review Logs & Analytics for HTTP 200 responses to protected paths that were served without a session. Correlate those requests with the rule that matched and with the source address. If the deployment does not keep request logs, an attempt that was served leaves no Pangolin-side record beyond the access itself.

Timeline

  • 2026-07-19: The fix is authored in commit 9561d23f1e77.
  • 2026-07-20: Pangolin 1.21.0 is released with the fix.
  • 2026-11-19: The vendor advisory GHSA-5h3v-3645-78xj is published.
  • 2026-11-24: VulnCheck publishes CVE-2026-136132.

The fix shipped in 1.21.0 on 2026-07-20, 122 days before the advisory named it. A deployment that stayed on the July release or later already carries the change.

The fix shipped 122 days before the advisory was published
Figure 1: The fix shipped on 2026-07-20, 122 days before the advisory was published. Source: GitHub commit 9561d23f1e77, the Pangolin 1.21.0 release, GHSA-5h3v-3645-78xj and CVE-2026-136132, checked November 24, 2026

FAQ

Does this affect Pangolin Cloud?

The advisory covers the server code before 1.21.0 and does not list a separate status for the hosted service. If you use Pangolin Cloud, ask Fossorial which version your instance runs.

Is my instance affected if I never created a path rule?

No. The bypass needs a path-based Bypass Auth rule with a wildcard. A resource with no rules, or with exact-path rules only, always requires authentication.

Does a Block Access rule stop the bypass?

No. A Block Access rule rejects only the paths that match its own pattern. A traversal path that avoids the block pattern is still evaluated against the other rules, and a bypass rule can match it.

Which backends expose the protected path?

Any backend that resolves .. or decodes %2F before routing. The advisory names Nginx, Node.js, Python's http.server and Go's http.FileServer; most web servers normalize paths this way.

Was CVE-2026-136132 exploited in the wild?

No exploitation is known, and the CVE is not in CISA KEV as of 2026-11-24. The advisory publishes a working request sequence, so the bypass is easy to reproduce where a wildcard rule exists.

Find exposed Pangolin instances with Ostorlab

Ostorlab's attack surface discovery inventories the internet-facing hosts and services an organisation runs, so the team knows which Pangolin deployments to check and patch first.

References

Free scan

Scan your own app for free

or book a demo

Keep reading

Related articles

Browse the blog