CVE-2026-62269

S3 object key query-string injection and truncation via unencoded reserved characters in ex_aws

Published Nov 24, 2026 CVSS 4.0 · 5.1 Medium EPSS n/a KEV · Not listed
Description
Improper Encoding or Escaping of Output vulnerability in ex_aws (S3 request URL construction).

This vulnerability is associated with program files lib/ex_aws/request/url.ex and program routines ExAws.Request.Url.build/2, ExAws.Request.Url.sanitize/2 and ExAws.Request.Url.get_path/2.

ex_aws does not percent-encode reserved characters in S3 object keys when it assembles the request URL. A literal ? in an object key survives unencoded: build/2 inserts the operation path verbatim and URI.to_string/1 emits it without encoding, and sanitize/2 then splits the flattened URL on the first ?, treating everything after it as the query string. Because the split runs before uri_encode is applied to the path, the ? is never neutralized, and the recovered query is re-inserted without any encoding.

An attacker who controls part of an object key (for example a download or upload keyed by a user-supplied filename) can therefore truncate the key past application-appended suffixes, causing the request to address a different object than the application intended, and can inject live S3 sub-resource operations (such as ?acl, ?tagging or ?versions) into the request. The manipulated URL is signed and transmitted normally, so the tampering is authorized like any legitimate request.

This issue affects ex_aws: from 2.1.2 before 2.8.0.

Analysis

No analysis available yet

Remediation

Vendor Workaround

Before constructing an S3 operation, percent-encode reserved characters in the object key (or reject keys that contain ? or #) so that no reserved character reaches the URL builder unencoded.

Tracking

Sign in to view the affected projects.

Advisories

No advisories available
History
Type Values Removed Values Added
Description Improper Encoding or Escaping of Output vulnerability in ex_aws (S3 request URL construction). This vulnerability is associated with program files lib/ex_aws/request/url.ex and program routines ExAws.Request.Url.build/2, ExAws.Request.Url.sanitize/2 and ExAws.Request.Url.get_path/2. ex_aws does not percent-encode reserved characters in S3 object keys when it assembles the request URL. A literal ? in an object key survives unencoded: build/2 inserts the operation path verbatim and URI.to_string/1 emits it without encoding, and sanitize/2 then splits the flattened URL on the first ?, treating everything after it as the query string. Because the split runs before uri_encode is applied to the path, the ? is never neutralized, and the recovered query is re-inserted without any encoding. An attacker who controls part of an object key (for example a download or upload keyed by a user-supplied filename) can therefore truncate the key past application-appended suffixes, causing the request to address a different object than the application intended, and can inject live S3 sub-resource operations (such as ?acl, ?tagging or ?versions) into the request. The manipulated URL is signed and transmitted normally, so the tampering is authorized like any legitimate request. This issue affects ex_aws: from 2.1.2 before 2.8.0.
Title S3 object key query-string injection and truncation via unencoded reserved characters in ex_aws
First Time appeared Ex-aws
Ex-aws ex Aws
Weaknesses CWE-116
CPEs cpe:2.3:a:ex-aws:ex_aws:*:*:*:*:*:*:*:*
Vendors & Products Ex-aws
Ex-aws ex Aws
References
Metrics cvssV4_0

{'score': 5.1, 'vector': 'CVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:N/VC:L/VI:L/VA:N/SC:N/SI:N/SA:N'}

Weaknesses
  • CWE-116

    Improper Encoding or Escaping of Output

Sources

Status
PUBLISHED
Assigner
EEF
Published
Updated
Nov 24, 2026, 11:40 AM
Reserved
Jul 13, 2026, 6:06 PM
Status
Received
Published
Nov 24, 2026, 12:17 PM
Modified
Nov 24, 2026, 12:17 PM