CVE-2026-131902: XML injection via unescaped VersionId in ExAws.S3.delete_multiple_objects/3

Published Nov 24, 2026
·
Updated

Summary

XML Injection vulnerability in ex-aws exawss3 allows an attacker who controls an object version id passed to ExAws.S3.deletemultipleobjects/3 to add objects to the batch delete.

deletemultipleobjects/3 in lib/exaws/s3.ex builds the <Delete> request body by placing each object's version between <VersionId> tags without XML escaping. A version such as v1</VersionId></Object><Object><Key>important-file</Key></Object><Object><Key>x</Key><VersionId>v2 closes the caller's object and opens new ones, so S3 deletes objects the application never listed, including other users' objects in the same bucket.

This issue affects exawss3: from 2.0.0 before 2.6.0.

Details

1. Selective escaping. When deletemultipleobjects/3 in lib/exaws/s3.ex builds the <Delete> body, it escapes each object's key with escapexmlstring/1 but emits the version from the same tuple raw: "<VersionId>", version, "</VersionId>".

2. Element break-out. XML metacharacters in version are read as markup. A value beginning </VersionId></Object> closes the current object early, and the rest of the string can open further <Object>...</Object> elements while keeping the document well-formed.

3. Extra deletes. The body POSTed to S3 lists more delete targets than the caller passed in, so a single crafted version id removes arbitrary additional objects in the bucket.

Proof of concept

1. An application lets a user delete a version of their own object and calls ExAws.S3.deletemultipleobjects("user-bucket", [{key, version}]) with the user's key and version. 2. The attacker sends the key my-own-file and the version v1</VersionId></Object><Object><Key>important-file</Key></Object><Object><Key>x</Key><VersionId>v2. 3. deletemultipleobjects/3 interpolates the version unescaped into the <Delete> body. 4. The body contains three <Object> entries, one of them important-file, which S3 deletes although the user never named it.

Impact

An attacker who controls a version id passed to deletemultipleobjects/3 can make the batched delete request remove arbitrary additional objects in the same bucket, including objects belonging to other users or critical to the application. Services that let users delete a specific object version by id are affected.

Configurations

Reachable only when the application passes a version id derived, even partially, from untrusted input to ExAws.S3.deletemultipleobjects/3, for example a service that lets users delete a specific object version by id.

Other sources

XML Injection vulnerability in ex-aws exawss3 allows an attacker who controls an object version id passed to ExAws.S3.deletemultipleobjects/3 to add objects to the batch delete.

deletemultipleobjects/3 in lib/exaws/s3.ex builds the <Delete> request body by placing each object's version between <VersionId> tags without XML escaping. A version such as v1</VersionId></Object><Object><Key>important-file</Key></Object><Object><Key>x</Key><VersionId>v2 closes the caller's object and opens new ones, so S3 deletes objects the application never listed, including other users' objects in the same bucket.

This issue affects exawss3: from 2.0.0 before 2.6.0.

— MITRE

Affected Software

2 affected componentsFixes available
hex/ex_aws_s3>=2.0.0<2.6.0
erlang/ex_aws_s3>=2.0.0<2.6.0
2.6.0

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade erlang/ex_aws_s3 to a version that resolves this vulnerability.

    Fixed in 2.6.0
  2. Upgrade

    Upgrade to a fixed release to a version that resolves this vulnerability.

    Fixed in 2.6.0

Event History

Nov 24, 2026
CVE Published
via MITRE·02:13 PM
Data Sourced
via MITRE·02:13 PM
DescriptionWeakness
Data Sourced
via OSV·02:13 PM
DescriptionSeverityWeaknessAffected Software

Frequently Asked Questions

1

Which deployments are affected?

Applications using ex_aws_s3 versions 2.0.0 through versions before 2.6.0 are affected when they call ExAws.S3.delete_multiple_objects/3 with object version IDs that may be attacker-controlled.

2

What must an attacker control to exploit this issue?

The attacker must be able to supply an object version ID passed into ExAws.S3.delete_multiple_objects/3. They can use XML markup in that value to introduce additional objects into the generated batch-delete request.

3

What is the practical impact?

The resulting S3 request can delete objects that the application did not explicitly include in the batch, including objects belonging to other users in the same bucket. Upgrade ex_aws_s3 to version 2.6.0 or later.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203