Incorrect Behavior Order: Validate Before Canonicalize Affecting varnish-cache package, versions [,8.0.1)


Severity

Recommended
0.0
medium
0
10

CVSS assessment by Snyk's Security Team. Learn more

Threat Intelligence

EPSS
0.2% (11th percentile)

Do your applications use this vulnerable package?

In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.

Test your applications
  • Snyk IDSNYK-UNMANAGED-VARNISHCACHE-15874413
  • published2 Apr 2026
  • disclosed27 Mar 2026
  • creditTom Kinnaird

Introduced: 27 Mar 2026

CVE-2026-34475  (opens in a new tab)
CWE-180  (opens in a new tab)

How to fix?

Upgrade varnish-cache to version 8.0.1 or higher.

Overview

Affected versions of this package are vulnerable to Incorrect Behavior Order: Validate Before Canonicalize in the HTTP/1.1 request if unchecked req.url gets passed to a backend which accepts requests with absolute form URIs. An attacker can manipulate cache contents or bypass authentication by crafting specific HTTP requests.

Note:

Varnish Cache LTS was patched in version 6.0.17.

Workaround

If upgrading is not possible, the problem can be mitigated by adding the following VCL snippet at the top of the VCL:

sub vsv18 {
  if (req.url == "*" && req.method == "OPTIONS") {
    return;
  }
  # NB: we do not allow connect by default (see vcl_req_method)
  if (req.url !~ "^/" && req.method != "CONNECT") {
    return (synth(400));
  }
}

sub vcl_recv { call vsv18; }

CVSS Base Scores

version 4.0
version 3.1