CVE-2026-49017: OpenStack Swift S3api Middleware Enters An Infinite Vulnerability

HIGH
Advisory Identifier: GHSA-g7jq-j257-rww2
CWE-835
Published
Advisory Summary

CVE-2026-49017 is a HIGH s3api middleware enters an infinite vulnerability (CWE-835: Loop with Unreachable Exit Condition ('Infinite Loop')) affecting OpenStack Swift libraries in the PyPI ecosystem. The issue involves s3api middleware enters an infinite loop when processing a truncated aws-chunked put request body. Remediation is available in the latest vendor maintenance releases.

CVE-2026-49017 at a Glance

CVE Identifier CVE-2026-49017
GHSA Identifier GHSA-g7jq-j257-rww2
Severity HIGH
CVSS v3.1 Base Score N/A
CWE Classification CWE-835: Loop with Unreachable Exit Condition ('Infinite Loop')
Affected Product OpenStack Swift
Package Ecosystem PyPI
Published Date
Last Updated

How to Fix CVE-2026-49017

To remediate this vulnerability, upgrade all affected OpenStack Swift dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

swift fixed: Latest secure release
pip install swift>=Latest secure release
swift fixed: Latest secure release
pip install swift>=Latest secure release
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

pip show swift

How to Check if You Are Affected

To determine whether your Python environment is affected by CVE-2026-49017, inspect your installed packages using pip:

pip show swift

Analyze the terminal output to locate any version of OpenStack Swift in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than the patched release), your application is affected.

Note: The pip show swift command checks currently installed packages in your active Python environment.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-835: Loop with Unreachable Exit Condition ('Infinite Loop'), where the product contains an iteration or loop with an exit condition that cannot be reached, i.e., an infinite loop. In OpenStack Swift, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

In OpenStack Swift before 2.36.2 and 2.37.2, s3api middleware enters an infinite loop when processing a truncated aws-chunked PUT request body. The StreamingInput class repeatedly appends an empty buffer and re-reads, causing the proxy-server worker handling the request to become permanently unresponsive with increasing CPU and memory consumption. An authenticated attacker can systematically exhaust all proxy-server workers, resulting in denial of service. The defect was introduced in Swift 2.36.0.

CVE-2026-49017 Affected OpenStack Swift Versions

2 component(s)
Product / Package Ecosystem Affected Versions Fixed Version
swift
PyPI
≥ 2.36.0
≤ 2.36.1
swift
PyPI
≥ 2.37.0
≤ 2.37.1

References

Frequently Asked Questions

What is CVE-2026-49017?
CVE-2026-49017 is a security vulnerability in OpenStack Swift involving s3api middleware enters an infinite loop when processing a truncated aws-chunked PUT request body under CWE-835: Loop with Unreachable Exit Condition ('Infinite Loop').
Which OpenStack Swift versions are affected?
Affected versions include releases prior to current release patches across affected packages: swift.
What version fixes CVE-2026-49017?
Upgrading to current release patches (or the latest patched release for your respective branch) resolves the vulnerability.
Is swift affected?
Yes, swift is affected in releases prior to Latest secure release. Upgrade your dependency to Latest secure release or later.
What CWE is associated with CVE-2026-49017?
CVE-2026-49017 is classified under CWE-835: Loop with Unreachable Exit Condition ('Infinite Loop') (The product contains an iteration or loop with an exit condition that cannot be reached, i.e., an infinite loop.).
How can I check PyPI dependencies for CVE-2026-49017?
Run the dependency tree command: 'pip show swift'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-g7jq-j257-rww2",
  "modified" : "2026-07-01T18:04:11Z",
  "published" : "2026-05-27T03:30:31Z",
  "aliases" : [ "CVE-2026-49017" ],
  "summary" : "OpenStack Swift: s3api middleware enters an infinite loop when processing a truncated aws-chunked PUT request body",
  "details" : "In OpenStack Swift before 2.36.2 and 2.37.2, s3api middleware enters an infinite loop when processing a truncated aws-chunked PUT request body. The StreamingInput class repeatedly appends an empty buffer and re-reads, causing the proxy-server worker handling the request to become permanently unresponsive with increasing CPU and memory consumption. An authenticated attacker can systematically exhaust all proxy-server workers, resulting in denial of service. The defect was introduced in Swift 2.36.0.",
  "severity" : [ {
    "type" : "CVSS_V4",
    "score" : "CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:L"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "PyPI",
      "name" : "swift"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "2.36.0"
      }, {
        "last_affected" : "2.36.1"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "PyPI",
      "name" : "swift"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "2.37.0"
      }, {
        "last_affected" : "2.37.1"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2026-49017"
  }, {
    "type" : "WEB",
    "url" : "https://bugs.launchpad.net/bugs/2152205"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/openstack/swift"
  }, {
    "type" : "WEB",
    "url" : "https://review.opendev.org/c/openstack/swift/+/987957"
  }, {
    "type" : "WEB",
    "url" : "https://review.opendev.org/c/openstack/swift/+/988093"
  }, {
    "type" : "WEB",
    "url" : "http://www.openwall.com/lists/oss-security/2026/05/27/9"
  }, {
    "type" : "WEB",
    "url" : "http://www.openwall.com/lists/oss-security/2026/06/02/6"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-835" ],
    "severity" : "HIGH",
    "github_reviewed" : true,
    "github_reviewed_at" : "2026-07-01T18:04:11Z",
    "nvd_published_at" : "2026-05-27T02:16:34Z"
  }
}