Swift Nio ExtrasApplication · Apple

CVE-2022-3252

HIGH · 7.5 CVSS v3.1 Published 2022-09-21
Fix available
A fix is available. Upgrade to 1.9.2 / 1.10.3 or later.
See remediation →
84/100
Remediation priority · High
Remotely reachable No privileges Zero-click

Official description Straight from the sourceThe vendor's or NVD's own wording, published unedited. Authoritative, but often terse — it says what broke, rarely what to do.

NVD · unedited
Improper detection of complete HTTP body decompression SwiftNIO Extras provides a pair of helpers for transparently decompressing received HTTP request or response bodies. These two objects (HTTPRequestDecompressor and HTTPResponseDecompressor) both failed to detect when the decompressed body was considered complete. If trailing junk data was appended to the HTTP message body, the code would repeatedly attempt to decompress this data and fail. This would lead to an infinite loop making no forward progress, leading to livelock of the system and denial-of-service. This issue can be triggered by any attacker capable of sending a compressed HTTP message. Most commonly this is HTTP servers, as compressed HTTP messages cannot be negotiated for HTTP requests, but it is possible that users have configured decompression for HTTP requests as well. The attack is low effort, and likely to be reached without requiring any privilege or system access. The impact on availability is high: the process immediately becomes unavailable but does not immediately crash, meaning that it is possible for the process to remain in this state until an administrator intervenes or an automated circuit breaker fires. If left unchecked this issue will very slowly exhaust memory resources due to repeated buffer allocation, but the buffers are not written to and so it is possible that the processes will not terminate for quite some time. This risk can be mitigated by removing transparent HTTP message decompression. The issue is fixed by correctly detecting the termination of the compressed body as reported by zlib and refusing to decompress further data. The issue was found by Vojtech Rylko (https://github.com/vojtarylko) and reported publicly on GitHub.

Technical summary Written by usOur analysis, written from the advisory, the CVSS vector and the affected-version data. It adds context the advisory leaves out, and never invents facts that are not in the source.

dbcve analysis · high confidence

SwiftNIO Extras HTTP decompression helpers (HTTPRequestDecompressor and HTTPResponseDecompressor) fail to detect when the decompressed body is complete. When trailing junk data is appended to a compressed HTTP message body, the code repeatedly attempts to decompress this data in an infinite loop, causing livelock and denial-of-service.

MitigationUpdate SwiftNIO Extras to the patched version that correctly detects zlib-reported termination of the compressed body, or remove transparent HTTP decompression if not required.

Verify against the referenced sources before acting — the references below are authoritative for this CVE, this summary is not.

Affected products & versions What the vendor confirmedThe version ranges the vendor confirmed as vulnerable. If your version sits inside a range here, treat yourself as exposed until you have upgraded.

NVD · CPE data
Swift Nio ExtrasApplication
Affected:< 1.9.2>= 1.10.0, < 1.10.3>= 1.11.0, < 1.14.0

CVSS breakdown How the score is builtThe industry scoring standard. It rates how the flaw is reached, what it takes to exploit, and what an attacker gains — the score is derived from those, not the other way round.

From the vector
Attack vector
Network
Complexity
Low
Privileges
None
User interaction
None
Scope
Unchanged
Confidentiality
None
Integrity
None
Availability
High

CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H

Am I affected? How to checkSteps we derive from the advisory and the affected-version data, so you can decide whether this CVE reaches your setup. They are a guide, not a scan — your own configuration is the authority.

dbcve checks

Work through these to decide whether this CVE applies to you.

  1. Identify SwiftNIO Extras version
    Check your project's dependency manifest (Package.swift, Package.resolved, or build system file) for the swift-nio-extras package version
    Affected if Version is < 1.9.2, or >= 1.10.0 and < 1.10.3, or >= 1.11.0 and < 1.14.0
  2. Confirm HTTP decompression is in use
    Search your codebase for imports of 'NIOHTTPCompression' and instantiation of 'HTTPRequestDecompressor' or 'HTTPResponseDecompressor' handlers in your SwiftNIO pipeline
    Affected if Either decompressor type is added to a ChannelPipeline and the version is vulnerable
  3. Check for exposed HTTP endpoints
    Inspect your server configuration to confirm HTTP decompression handlers are applied to public-facing or internal HTTP services
    Affected if Decompression handlers are enabled on any HTTP server and version is vulnerable
  4. Review runtime dependency configuration
    If using a package manager, run 'swift package show-dependencies' or inspect your lock file for the exact resolved version of swift-nio-extras
    Affected if Resolved version matches the affected ranges listed above

You are affected if SwiftNIO Extras with a version in the ranges < 1.9.2, >= 1.10.0 to < 1.10.3, or >= 1.11.0 to < 1.14.0 is deployed and HTTPRequestDecompressor or HTTPResponseDecompressor are actively decompressing HTTP bodies in your environment.

Generated from the published advisory. Verify against your own configuration.

Check your environment

Paste your version and any relevant configuration and it will be compared against the affected criteria above. Do not include secrets or credentials.

AI-assisted, checked against the advisory. Informational, not a guarantee.

Remediation Closing itWhat it takes to close this. Where a vendor fix exists we point at it; where none exists we say so plainly, and can build one. Effort estimates are scoped from the advisory, not from your codebase.

dbcve · scoped
Upgrade available Upgrade to 1.9.2 / 1.10.3 / 1.14.0 or later
Fixed in 1.9.21.10.31.14.0
Interim mitigation

Update SwiftNIO Extras to the patched version that correctly detects zlib-reported termination of the compressed body, or remove transparent HTTP decompression if not required.

Recommended fix High confidence

SwiftNIO Extras version 1.14.0 or later

  1. 1. Identify the current version of SwiftNIO Extras in your project by checking your Package.swift, Podfile, or dependency lock file
  2. 2. If using Swift Package Manager, update the dependency to version 1.14.0 or later: Change the dependency from 'from: "1.0.0"' or similar to 'from: "1.14.0"' in your Package.swift
  3. 3. If using CocoaPods, update your Podfile to specify the version: pod 'SwiftNIOExtras', '~> 1.14' and run pod update
  4. 4. Rebuild and test your application to verify the fix resolves the infinite loop issue
  5. 5. Monitor the application after deployment to confirm the livelock vulnerability is mitigated
Caveat No breaking changes expected; this is a bug fix for an infinite loop vulnerability

Generated from the published advisory — verify against the referenced sources before acting.

Fix this in Swift Nio Extras Scoped from the published advisory
  • Consultation2.0 h
  • Implementation2.0 h
  • Testing3.0 h
  • Review / QA1.0 h
8.0 hours of engineering $1,390
Get the upgrade done

An estimate, not a bill — we confirm scope with you before any work starts. Need it this week? Rush from $2,224.

Scan for this in your stack

Free · runs locally
dbcve dependency scanner

Check whether your project pulls in CVE-2022-3252 — or any other known-vulnerable package — straight from your lock files. Free and open source; it runs locally and uploads nothing.

References Go to the primary sourcePrimary sources — vendor advisories, patches and trackers. Where our summary and a reference disagree, the reference wins.

Primary sources

Practitioner notes

Contributed

Peer-ranked notes from engineers who’ve handled CVE-2022-3252 in production — separate from our analysis above.

No notes yet

Be the first to add a field note for this CVE — a mitigation you’ve verified, a version caveat, or a link to a working fix. Sign in above to contribute.

What this is

A place for practitioners to share what actually worked: a mitigation you’ve tested, a configuration change, a version- or environment-specific caveat, or a link to a verified patch. The most useful notes rise to the top as peers upvote them, so the signal stays high.

What belongs here
  • Verified mitigations, workarounds, and config changes
  • Version or environment caveats, and links to real fixes
  • No weaponised exploit code, or anything meant to cause harm
  • No spam, self-promotion, credentials, or personal data