CVEReports
CVEReports

Automated vulnerability intelligence platform. Comprehensive reports for high-severity CVEs generated by AI.

Product

  • Home
  • Sitemap
  • RSS Feed

Company

  • About
  • Contact
  • Privacy Policy
  • Terms of Service

© 2026 CVEReports. All rights reserved.

Made with love by Amit Schendel & Alon Barad



CVE-2026-84428

CVE-2026-84428: Schema Validation Bypass in Fastify Header Normalization

Amit Schendel
Amit Schendel
Senior Security Researcher

Oct 1, 2026·8 min read·19 visits

Executive Summary (TL;DR)

A shallow header-schema normalization bug in Fastify < 5.12.2 allows unauthenticated remote attackers to bypass critical conditional header validation rules, silently skipping security checks if trigger headers are defined in mixed-case.

A validation bypass vulnerability exists in Fastify web framework prior to version 5.12.2. The flaw stems from shallow normalization of header validation schemas, which fails to lowercase nested or conditional schema rules (like JSON Schema dependencies or dependentRequired) defined in mixed or canonical casing. Consequently, because Node.js normalizes incoming HTTP request headers to lowercase, the compiled validator fails to match these headers against the un-normalized mixed-case schema triggers, silently skipping conditional checks and allowing unauthenticated attackers to bypass authorization or security headers.

Vulnerability Overview

Fastify is a highly optimized web framework for Node.js that prioritizes performance and low overhead. To enforce data integrity and structure HTTP requests, developers commonly declare validation schemas for different request components, including route headers. When incoming requests are received, Fastify leverages schema validation engines like Ajv to verify that the headers comply with specified formats, constraints, and dependencies before passing execution to the route handler.

HTTP headers are case-insensitive by specification according to RFC 9110, meaning headers like X-Admin and x-admin must be treated as identical. To handle this, Node.js automatically normalizes all incoming request headers to lowercase inside the request.headers object. Fastify aligns with this behavior by lowercasing the keys in developer-defined header schemas during the pre-compilation phase, ensuring that the validator matches incoming lowercase request data against the schema parameters.

CVE-2026-84428 represents a validation bypass vulnerability in Fastify's schema preprocessing logic where normalization was performed only on a shallow level. If a developer declared case-insensitive conditional schema keywords such as dependencies or dependentRequired using canonical or mixed casing, Fastify failed to recursively lowercase these internal subschema properties. Consequently, the validator was compiled with mixed-case rules that failed to match the incoming lowercased headers, allowing attackers to bypass validation rules designed to enforce dependent or mandatory parameters.

Root Cause Analysis

The root cause of CVE-2026-84428 lies in the shallow traversal of header validation schemas prior to compilation in Fastify's core validation module (lib/validation.js). Specifically, the framework's schema normalization utility only converted the primary keys inside the top-level properties object and the root-level required array to lowercase. It did not recursively walk the schema to find other properties that referenced header names.

This behavior becomes problematic when developers utilize JSON Schema draft features to establish conditional requirements. Keywords like JSON Schema Draft 7 dependencies or Draft 2019-09 dependentRequired and dependentSchemas are designed to enforce validation rules based on the presence of certain keys. When these structures are defined with mixed-case or canonical header names, they remain unchanged after Fastify's shallow normalization pass.

During execution, the JSON Schema validator parses the incoming headers, which have already been lowercased by Node.js. When the validator encounters a lowercased header, it looks for any dependency constraints matching that lowercase key in the compiled schema. Because the dependency triggers in the schema were not normalized and remain in mixed-case, the validator finds no corresponding rule and silently skips the dependency check, failing to enforce the required conditional headers.

Code Analysis & Patch Walkthrough

Prior to the release of the patch, Fastify performed a simplistic object-cloning operation to normalize headers. The framework initialized a shallow copy of the schema's root properties and lowercased only those specific paths as demonstrated in the following snippet:

// Vulnerable implementation in lib/validation.js
const headersSchemaLowerCase = {}
Object.keys(headers).forEach(k => { headersSchemaLowerCase[k] = headers[k] })
if (headersSchemaLowerCase.required instanceof Array) {
  headersSchemaLowerCase.required = headersSchemaLowerCase.required.map(h => h.toLowerCase())
}
if (headers.properties) {
  headersSchemaLowerCase.properties = {}
  Object.keys(headers.properties).forEach(k => {
    headersSchemaLowerCase.properties[k.toLowerCase()] = headers.properties[k]
  })
}

To resolve this issue, the maintainers implemented a recursive function named lowerCaseHeadersSchema which traverses the entire JSON Schema tree. This function maps and translates keys in every nested object, conditional block, and logical combinator, ensuring that properties inside dependencies, dependentRequired, and dependentSchemas are thoroughly normalized. The updated implementation iterates recursively as shown below:

// Patched implementation in lib/validation.js
function lowerCaseHeadersSchema (schema) {
  if (Array.isArray(schema)) {
    return schema.map(lowerCaseHeadersSchema)
  }
  if (schema === null || typeof schema !== 'object') {
    return schema
  }
 
  const result = {}
  for (const key of Object.keys(schema)) {
    const value = schema[key]
    switch (key) {
      case 'properties': {
        // Recurse and lowercase keys of the properties map
        const normalized = {}
        for (const prop of Object.keys(value)) {
          normalized[prop.toLowerCase()] = lowerCaseHeadersSchema(value[prop])
        }
        result.properties = normalized
        break
      }
      case 'required':
        result.required = Array.isArray(value) ? value.map(name => name.toLowerCase()) : value
        break
      case 'dependencies': {
        // Normalize trigger keys and dependent property lists
        const normalized = {}
        for (const dep of Object.keys(value)) {
          const depValue = value[dep]
          if (Array.isArray(depValue)) {
            normalized[dep.toLowerCase()] = depValue.map(name => name.toLowerCase())
          } else {
            normalized[dep.toLowerCase()] = lowerCaseHeadersSchema(depValue)
          }
        }
        result.dependencies = normalized
        break
      }
      // Additional cases handle dependentSchemas, dependentRequired, allOf, anyOf, etc.
    }
  }
  return result
}

While the recursive implementation correctly handles inline schemas, the maintainers identified a limitation: schemas referencing external definitions via $ref cannot be safely mutated. Modifying shared external schemas could disrupt other route components that require case preservation (e.g., body parameters). Consequently, Fastify introduced findExternalHeaderRef to analyze schemas for external references and emit warning code FSTSEC002 if any are detected.

Exploitation Methodology & Proof of Concept

Exploitation of CVE-2026-84428 requires a target endpoint that uses case-sensitive validation conditions on incoming HTTP headers. An attacker can craft a request that triggers a validation bypass if they omit the required secondary security header while providing the primary conditional header.

Consider an application that uses a header-triggered privileged flow. The schema mandates that if the client sends X-Admin: true, they must also supply a secret authorization key in X-Admin-Token. This behavior is defined programmatically using a dependencies statement in Fastify:

// Vulnerable validation definition
headers: {
  type: 'object',
  properties: {
    'X-Admin': { type: 'string', const: 'true' },
    'X-Admin-Token': { type: 'string', const: 'secret-token-1234' }
  },
  dependencies: {
    'X-Admin': ['X-Admin-Token']
  }
}

To execute the exploit, an attacker submits a GET request containing the primary header X-Admin: true while completely omitting X-Admin-Token. Because Node.js normalizes the incoming headers, the schema validator evaluates the request against x-admin. Since the dependency keyword specifies X-Admin, the validator skips the verification block entirely, executing the route handler and granting administrative access without credentials.

An administrative bypass of this nature is reproducible programmatically. Security engineers can verify whether an endpoint is vulnerable by using a local test harness to send mismatched header payloads and monitoring whether Fastify accepts requests that should be rejected with a 400 Bad Request response.

Impact & Security Implications

The impact of CVE-2026-84428 is classified as High, with a CVSS base score of 7.5. The vulnerability allows unauthenticated remote attackers to bypass application-level validation logic, potentially circumventing defense mechanisms designed to protect privileged routes. If an application uses conditional header checks to verify authentication tokens, tenant routing identifiers, or environment contexts, the bypass can result in unauthorized access to sensitive application components.

Because the flaw resides entirely within the validation compilation phase, exploitation does not leave typical application error signatures. The target application processes the requests as syntactically and semantically valid, meaning security teams cannot detect exploit attempts using standard server logs unless they specifically audit header structures on incoming traffic.

This vulnerability has not been observed in active exploitation, nor has it been added to CISA's Known Exploited Vulnerabilities catalog. However, the presence of public proof-of-concept tests within the framework repository increases the likelihood of reverse engineering and targeted attacks against outdated deployments of Fastify.

Remediation & Hardening Strategies

The primary remediation path is to upgrade all Fastify installations to version 5.12.2 or later. This ensures that the schema compiler utilizes the recursive lowerCaseHeadersSchema utility to properly normalize all internal and conditional properties prior to validation.

In scenarios where immediate patching is not feasible, developers must manually rewrite schemas to avoid mixed-case definitions. Modifying all header validation schemas to use strictly lowercase keys in both the properties block and any conditional keywords (such as dependencies or dependentRequired) will align the validation rules with the pre-compiled headers, neutralizing the bypass vector.

Additionally, developers must audit their applications for the FSTSEC002 warning code. If a headers schema references external definitions via $ref, Fastify will skip automatic normalization to prevent side effects on other schema consumers. To resolve this, external schemas containing header validations should be inlined or defined locally within the route schema.

For defense-in-depth, security teams should implement auxiliary middleware validation hooks. Standardizing manual verification of critical security headers inside a preHandler hook provides a secondary validation layer that does not rely on declarative schema engines, ensuring consistent protection against parser-level discrepancies.

Official Patches

fastifyRecursive lowercase headers schema and FSTSEC002 check commit
fastifyv5.12.2 patch release commit

Fix Analysis (2)

Technical Appendix

CVSS Score
7.5/ 10
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N
EPSS Probability
0.52%
Top 58% most exploited

Affected Systems

Fastify < 5.12.2

Affected Versions Detail

Product
Affected Versions
Fixed Version
Fastify
fastify
< 5.12.25.12.2
AttributeDetail
Vulnerability TypeImproper Handling of Case Sensitivity (CWE-178)
Attack VectorNetwork (AV:N)
CVSS Base Score7.5 (High)
EPSS Score0.00524 (Percentile: 42.21%)
Exploit MaturityProof-of-Concept (PoC)
CISA KEV StatusNot Listed

MITRE ATT&CK Mapping

T1562.001Impair Defenses: Disable or Modify Tools
Defense Evasion
T1190Exploit Public-Facing Application
Initial Access
CWE-178
Improper Handling of Case Sensitivity

The software performs a case-sensitive comparison of an identifier or resource name that should be case-insensitive, leading to validation gaps.

Known Exploits & Detection

GitHub Test SuiteProgrammatic proof-of-concept showing dependency verification bypass using mixed-case header configurations.

Vulnerability Timeline

Core validation recursive mapping patch committed to master repository
2026-09-03
Extended tests merged and Fastify v5.12.2 tag officially released
2026-09-04
GitHub Security Advisory GHSA-9q9j-q6p8-xq58 and CVE-2026-84428 published
2026-09-04

References & Sources

  • [1]GHSA-9q9j-q6p8-xq58: Case insensitivity bypass in header validation schemas
  • [2]NVD - CVE-2026-84428
  • [3]OpenJS Foundation Security Advisories

Attack Flow Diagram

Press enter or space to select a node. You can then use the arrow keys to move the node around. Press delete to remove it and escape to cancel.
Press enter or space to select an edge. You can then press delete to remove it or escape to cancel.

More Reports

•36 minutes ago•CVE-2026-46429
5.5

CVE-2026-46429: Unrestricted File Upload and Validation Bypass in GeoNode

GeoNode versions prior to 5.0.3 contain an unrestricted file upload vulnerability (CWE-434) within the document and dataset ingestion architecture. Authenticated low-privileged users can bypass upload validation via direct REST API interactions, file extension masquerading, metadata mutation via PATCH requests, or malicious archive submissions. This allows attackers to store and serve dangerous file types, alter on-disk file references, or trigger path traversal and resource exhaustion during archive extraction.

Amit Schendel
Amit Schendel
1 views•10 min read
•about 2 hours ago•CVE-2026-55649
6.3

CVE-2026-55649: Stored Cross-Site Scripting in GeoNode Document Metadata Abstract Field

CVE-2026-55649 is a stored Cross-Site Scripting (XSS) vulnerability in GeoNode versions prior to 5.0.3. The flaw exists because document abstract metadata fields are ingested via the metadata management pipeline and stored in the backend database without HTML sanitization or input neutralization. An authenticated attacker with privileges to create or edit document metadata can inject arbitrary HTML and JavaScript payloads into these fields. When another user, such as an administrator, views the affected document page or catalog listing, the unencoded payload is rendered into the Document Object Model (DOM) and executes within the victim's browser session.

Amit Schendel
Amit Schendel
4 views•9 min read
•about 3 hours ago•GHSA-QX75-2P3R-PWM5
7.7

CVE-2026-55622: Cross-Project Instance Copy Authorization Bypass in Canonical LXD and LXC Incus

CVE-2026-55622 (GHSA-qx75-2p3r-pwm5) is an improper access control vulnerability (CWE-284) in Canonical LXD and LXC Incus (tracked as GHSA-c9f5-j9c3-mhrg). In multi-tenant deployments utilizing project-based isolation, the REST API handler for instance creation via POST /1.0/instances verifies that the authenticated user has authorization in the destination project specified by the query parameter, but fails to verify whether the user holds read or view permissions for the source instance when executing a copy operation across projects. Consequently, an authenticated client restricted to a single project can clone instances or snapshots from unauthorized projects into their own project, resulting in complete disclosure of the target instance filesystem and embedded credentials.

Amit Schendel
Amit Schendel
3 views•11 min read
•about 4 hours ago•GHSA-7MR3-28H5-M5VX
7.7

GHSA-7mr3-28h5-m5vx: Authorization Bypass and Cross-Project Volume Copy in Canonical LXD

An authorization bypass vulnerability in Canonical LXD (tracked as GHSA-7mr3-28h5-m5vx and CVE-2026-55621, and as GHSA-64f3-v33m-w89f in Linux Containers Incus) allows an authenticated user with restricted project access to copy custom storage volumes and volume snapshots from unauthorized projects. The flaw resides in the storagePoolVolumesPost REST API handler, which verifies permissions on the destination project but fails to check whether the caller holds view entitlements on the source project or volume specified in the request body.

Alon Barad
Alon Barad
3 views•10 min read
•about 5 hours ago•GHSA-47W9-6R3F-938G
9.9

GHSA-47w9-6r3f-938g: Authorization Bypass and Host Root Command Execution in Canonical LXD and Incus

A missing authorization and configuration validation vulnerability in Canonical LXD and LXC Incus allows authenticated users within restricted projects to bypass project security boundaries. By smuggling prohibited low-level configuration directives (such as raw.lxc or raw.qemu) inside instance snapshots or backup archives, an attacker can restore these configurations within a restricted project and execute arbitrary commands with root privileges on the underlying host operating system.

Alon Barad
Alon Barad
4 views•11 min read
•about 6 hours ago•GHSA-JPF8-86F3-WP38
9.9

CVE-2026-48752: Arbitrary Host File Read and Write via Templates Symlink in Canonical LXD and Incus

A symbolic link traversal vulnerability (CWE-59) in Canonical LXD and Linux Containers Incus allows an authenticated user with image import permissions to read and write arbitrary files on the host filesystem. During image archive unpacking, the daemon fails to reject top-level symbolic links for the instance `templates` directory. Subsequent requests to the instance template API endpoints follow this symbolic link outside the instance storage directory with root privileges, enabling complete host compromise.

Amit Schendel
Amit Schendel
4 views•10 min read