Vulnerability DatabaseCVE-2026-118515

CVE-2026-118515: 
PHP vulnerability analysis and mitigation

Overview

CVE-2026-118515 is a file path control vulnerability in the Symfony Serializer component (symfony/serializer) that allows unauthenticated attackers to treat arbitrary server-side files as uploaded files by supplying attacker-controlled deserialization data. The root cause is that DataUriNormalizer only handled the exact types SplFileInfo, SplFileObject, and File, leaving subclasses such as UploadedFile to be instantiated by ObjectNormalizer directly from request-supplied fields — including the file path. Affected versions are symfony/serializer prior to 5.4.56, 6.x prior to 6.4.50, 7.x prior to 7.4.23, and 8.x prior to 8.1.11. The vulnerability was reported by Oliver Wenzel, fixed by Nicolas Grekas, and publicly disclosed on November 4, 2026. It carries a CVSS v4 base score of 8.4 (High) (GitHub Advisory, Symfony Blog).

Technical details

The vulnerability is classified as CWE-73 (External Control of File Name or Path). DataUriNormalizer::supportsDenormalization() previously returned true only for the exact types SplFileInfo, SplFileObject, and File; when a DTO property was typed as a subclass (e.g., UploadedFile), the serializer fell through to ObjectNormalizer, which instantiated the object via its constructor using attacker-supplied fields including path, originalName, and test. Setting test: true causes UploadedFile::isValid() to skip the is_uploaded_file() PHP check, and move() falls back to rename(), meaning no actual file upload is required. The fix extends DataUriNormalizer::supportsDenormalization() to claim all SplFileInfo subclasses and rejects non-instance data with a NotNormalizableValueException (GitHub Advisory, Patch Commit 72ece5b, Patch Commit c459104).

Impact

A successful exploit allows an unauthenticated attacker to read any file readable by the PHP process (e.g., .env.local, configuration files, credentials), move arbitrary server files when the application calls move() on the upload object, and enumerate whether arbitrary file paths exist on the server. The Assert\File constraint does not mitigate this because it validates the real file at the attacker-chosen path, which legitimately exists. Applications using #[MapRequestPayload] with a DTO containing an UploadedFile property — the standard pattern in Symfony 8.1 — are exploitable with a single unauthenticated HTTP request (GitHub Advisory, Symfony Blog).

Exploitability

A proof-of-concept JSON payload is publicly documented in the GitHub Security Advisory, demonstrating exploitation via a crafted request body with no authentication required. No evidence of in-the-wild exploitation has been reported as of the disclosure date. The EPSS score is 0.0058 (approximately 0.58%), indicating low but non-negligible probability of exploitation in the near term. The vulnerability is not currently listed in the CISA KEV catalog. NVD SSVC assessment marks it as automatable (GitHub Advisory, Feedly).

Exploitation steps

  1. Reconnaissance: Identify Symfony applications using #[MapRequestPayload] on a controller action where the DTO contains an UploadedFile-typed property, or any endpoint that deserializes untrusted JSON/form data into such a type. Confirm the Symfony version is within an affected range (<5.4.56, >=6 <6.4.50, >=7 <7.4.23, >=8 <8.1.11).
  2. Craft the malicious payload: Construct a JSON body that populates the UploadedFile-typed property with attacker-controlled fields, specifying a target server file path, a benign-looking original name, and test: true to bypass is_uploaded_file() validation:
{"name": "x", "image": {"path": "/path/to/project/.env.local", "originalName": "a.png", "test": true}}
  1. Send the request: Submit the crafted JSON body (or equivalent form-encoded body) as a POST request to the vulnerable endpoint with Content-Type: application/json. No authentication or file upload is required.
  2. Trigger application file handling: The Symfony serializer routes the UploadedFile-typed property to ObjectNormalizer, which constructs an UploadedFile object pointing at the specified server path. The application then processes this object as a legitimate upload.
  3. Achieve objective: Depending on application behavior — if the upload is stored and served back, the attacker receives the contents of the targeted server file (e.g., secrets from .env.local); if move() is called, the file is relocated; if only existence is checked, path enumeration is achieved (GitHub Advisory, Symfony Blog).

Indicators of compromise

  • Network: Unexpected POST requests to file-upload endpoints containing JSON bodies with UploadedFile-like fields (path, originalName, test: true) but no multipart file data; requests where the image or similar field contains a JSON object rather than a data URI or file stream.
  • Logs: Web server access logs showing POST requests to upload-handling routes with Content-Type: application/json and response codes of 200 (successful file disclosure) or 422 (patched/rejected); PHP error logs referencing NotNormalizableValueException on patched systems indicating attempted exploitation.
  • File System: Unexpected relocation or disappearance of sensitive server files (e.g., .env, .env.local, configuration files) if the application calls move() on the upload object; new files appearing in upload storage directories that match names of known server-side configuration files.
  • Process: PHP process accessing files outside the expected upload temporary directory (e.g., /etc/, application root config files) as observed via file access auditing (e.g., auditd or inotifywait).

Mitigation and workarounds

Symfony has released patched versions: 5.4.56, 6.4.50, 7.4.23, and 8.1.11 — upgrading to one of these is the primary recommended remediation (GitHub Advisory, Symfony Blog). For applications unable to patch immediately: avoid using #[MapRequestPayload] on DTOs with UploadedFile properties on publicly accessible endpoints; implement strict server-side validation of deserialized file objects before any read, move, or serve operation; and ensure DataUriNormalizer is registered ahead of ObjectNormalizer in the serializer chain (the FrameworkBundle-configured serializer does this by default). Note that a serializer built without DataUriNormalizer ahead of ObjectNormalizer does not receive the protection from the patch.

Community reactions

Symfony credited Oliver Wenzel for discovering and reporting the vulnerability, Nicolas Grekas for the fix, and Bruno Dias and Miguel Neves from Checkmarx for assistance in obtaining CVE assignment (GitHub Advisory). The Symfony project published a detailed blog post and security advisory simultaneously with the patch release on November 4, 2026 (Symfony Blog). Tenable published a Nessus detection plugin (ID 376252) shortly after disclosure, indicating rapid uptake by the security tooling community.

Additional resources

Linux Distribution fix status

Fix availability across major Linux distributions and their releases.

Debian

Fixed

bookworm

symfony

Affected

sid

symfony: 7.4.23+dfsg-1

Fixed

trixie

symfony: 6.4.50+dfsg-0+deb13u1

Fixed

Ubuntu

Unknown

bionic (esm-apps)

symfony

Unknown

devel

symfony

Unknown

focal (esm-apps)

symfony

Unknown

jammy

symfony

Unknown

jammy (esm-apps)

symfony

Unknown

noble

symfony

Unknown

noble (esm-apps)

symfony

Unknown

resolute

symfony

Unknown

Source: This report was generated using AI

Related PHP vulnerabilities:

CVE ID

Severity

Score

Technologies

Component name

CISA KEV exploit

Has fix

Published date

CVE-2026-104883HIGH7.2
  • PHP logoPHP
  • contao/core-bundle
NoYesNov 20, 2026
GHSA-vw9g-2c4c-g767MEDIUM6.8
  • PHP logoPHP
  • livewire/livewire
NoYesNov 21, 2026
CVE-2026-104882MEDIUM6.5
  • PHP logoPHP
  • cpe:2.3:a:contao:contao
NoYesNov 20, 2026
GHSA-2g6w-c7gx-fxj8MEDIUM5.4
  • PHP logoPHP
  • guzzlehttp/guzzle
NoYesNov 21, 2026
CVE-2026-104884MEDIUM5.4
  • PHP logoPHP
  • composer://contao/contao
NoYesNov 20, 2026

Free Vulnerability Assessment

Benchmark your Cloud Security Posture

Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.

Request assessment

Additional Wiz resources

Get a personalized demo

Ready to see Wiz in action?

"Best User Experience I have ever seen, provides full visibility to cloud workloads."
David EstlickCISO
"Wiz provides a single pane of glass to see what is going on in our cloud environments."
Adam FletcherChief Security Officer
"We know that if Wiz identifies something as critical, it actually is."
Greg PoniatowskiHead of Threat and Vulnerability Management