MEDIUM 5.3

CVE-2026-28898: Swift-NIO-HTTP2 Pseudo-Header Validation Bypass – Header Injection Risk

Swift-NIO-HTTP2, Apple's open-source networking library for HTTP/2 protocol handling, contains a validation gap in its HTTP/2-to-HTTP/1.1 converter. The library failed to check pseudo-header values (like :path, :authority, :scheme, :method, and :status) for control characters—specifically carriage return (CR), line feed (LF), and null (NUL) bytes—before translating HTTP/2 frames into HTTP/1.1 messages. An attacker could craft malicious HTTP/2 requests or responses containing these characters to bypass security controls or potentially inject unintended content into downstream systems that process the converted HTTP/1.1 messages. Version 1.44.1 and later reject such messages at the connection level.

Source data · NVD / CISA · public domain

CVSS
3.1 · 5.3 MEDIUM · CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:N
Weaknesses (CWE)
CWE-116
Affected products
1 configuration(s)
Published / Modified
2026-06-25 / 2026-06-30

NVD description (verbatim)

swift-nio-http2's HTTP/2-to-HTTP/1.1 codec did not validate pseudo-header values for control characters before placing them into the translated HTTP/1.1 message. swift-nio-http2 1.44.1 adds validation of all pseudo-header values (:path, :authority, :scheme, :method, and :status) at both the HPACK header validation layer and the HTTP/2-to-HTTP/1.1 translation layer. Requests or responses containing CR, LF, or NUL bytes in any pseudo-header value are now rejected with a connection error. This issue is fixed in swift-nio-http2 1.44.1.

1 reference(s) · View on NVD →

SEC.co analysis · AI-assisted, reviewed against source

Technical summary

The vulnerability resides in swift-nio-http2's HPACK header processing and HTTP/2-to-HTTP/1.1 translation logic. HTTP/2 uses pseudo-headers (prefixed with ':') that carry critical metadata; these must be sanitized before translation to HTTP/1.1's header format. The codec did not validate pseudo-header values for CR (0x0D), LF (0x0A), or NUL (0x00) bytes, which are line-breaking or string-terminating control characters. In HTTP/1.1, these characters can be interpreted as header delimiters or terminators, potentially allowing header injection or request smuggling attacks when processed by downstream systems. The fix implements validation at two layers: HPACK validation during frame parsing and an additional check during the HTTP/2-to-HTTP/1.1 translation step. Non-compliant messages now trigger immediate connection closure with a protocol error.

Business impact

HTTP/2-to-HTTP/1.1 conversion gateways using swift-nio-http2 could become conduits for header injection attacks. If a reverse proxy or load balancer built on this library sits between untrusted clients and backend HTTP/1.1 services, attackers could inject CR/LF bytes to craft malicious headers that bypass authentication, inject content, or confuse request routing. The impact depends on downstream application behavior; some systems may ignore malformed headers, while others may misinterpret them. Organizations relying on swift-nio-http2 for API gateways, proxies, or protocol translation should prioritize patching to prevent request smuggling and header injection scenarios.

Affected systems

Apple's swift-nio-http2 library versions prior to 1.44.1 are affected. Any application or service that uses swift-nio-http2 for HTTP/2 handling is potentially vulnerable, including custom HTTP/2 servers, reverse proxies, API gateways, and protocol converters built in Swift. The vulnerability is most concerning in deployments where swift-nio-http2 translates HTTP/2 traffic from untrusted external clients to HTTP/1.1 backend services. Server applications are at higher risk than client libraries, though client-side translation could theoretically be exploited if a malicious HTTP/2 server responds with crafted pseudo-headers.

Exploitability

The vulnerability requires no authentication, no user interaction, and no special network positioning beyond the ability to send HTTP/2 requests to the affected service. The attack surface is network-adjacent (AV:N, AC:L per CVSS). However, successful exploitation depends on downstream system behavior: some HTTP/1.1 parsers may silently drop malformed headers, limiting impact. The CVSS score of 5.3 (MEDIUM) reflects the confidentiality impact (C:L) from potential header-based information disclosure or bypass of security controls, but no integrity or availability impact in the base case. Real-world risk scales with the trust relationship between the HTTP/2 entry point and backend services.

Remediation

Upgrade swift-nio-http2 to version 1.44.1 or later immediately. This applies to any Swift-based application or service using the library. Verify the version in your dependency management files (Package.swift, Podfile, etc.) and apply the security patch through your normal release and deployment pipeline. If you maintain a downstream product that bundles swift-nio-http2, prioritize a security release for your customers. No workarounds are available; patching is the only mitigation.

Patch guidance

Update swift-nio-http2 to 1.44.1 or a later version. For projects using Swift Package Manager, update the package requirement in Package.swift; for CocoaPods, update the podspec. Perform functional testing on HTTP/2 traffic after patching to confirm protocol translation continues to work correctly. The fix is backward-compatible at the API level—no code changes are required in consuming applications, only the dependency version update. Verify against the official Apple swift-nio-http2 repository and release notes to confirm version 1.44.1 is available in your preferred package manager.

Detection guidance

Monitor HTTP/2 traffic for unusual pseudo-header values containing control characters (CR, LF, NUL). Intrusion detection systems should flag HTTP/2 frames where pseudo-headers (identified by the ':' prefix) contain these bytes. Log and review connection errors or protocol violations from swift-nio-http2 services, as the patched version will reject such requests with connection closure. If you run vulnerable versions, inspect access logs for any evidence of requests with anomalous header patterns, though such requests may not be logged if parsing fails early. Consider network-based detection of HTTP/2 frames with embedded control characters in the header block.

Why prioritize this

Although CVSS is MEDIUM (5.3), this vulnerability should be prioritized as HIGH for deployment if your service acts as an HTTP/2 gateway or reverse proxy. The lack of KEV designation suggests no active exploitation has been observed, but the simplicity of crafting malicious HTTP/2 frames and the potential for request smuggling warrant rapid patching. HTTP/2-to-HTTP/1.1 translation is a common architectural pattern; delaying the patch increases risk of opportunistic attacks. Patch within 30 days for internet-facing services, sooner for edge/gateway deployments.

Risk score, explained

The CVSS:3.1 score of 5.3 reflects a low barrier to exploitation (network-accessible, no authentication or user interaction required) but limited direct impact (confidentiality impact only, no integrity or availability impacts in the base case). The severity is MEDIUM. However, context matters: if the affected library is exposed to untrusted HTTP/2 clients in a gateway role, the actual risk is elevated due to the potential for request smuggling and downstream bypass attacks. The lack of assigned KEV status indicates this is not yet known to be exploited in the wild, reducing urgency slightly but not eliminating it.

Frequently asked questions

What is HTTP/2 pseudo-header validation and why does it matter?

HTTP/2 uses pseudo-headers (like :path, :authority, :method) to convey request/response metadata efficiently. These are distinct from HTTP/1.1 headers and must comply with strict formatting rules. Control characters in pseudo-header values can break HTTP/1.1 parsing or be misinterpreted as header delimiters when the HTTP/2 message is translated to HTTP/1.1 format, enabling injection attacks. Validation prevents this by rejecting frames with forbidden characters before translation occurs.

Do I need to change my application code to deploy the patch?

No. The patch to swift-nio-http2 1.44.1 is a library-level fix requiring only a dependency version update. Your application code does not need to change. Simply update the package reference in your Package.swift or Podfile and rebuild. The library will automatically reject non-compliant HTTP/2 frames.

What happens to requests with control characters in pseudo-headers after patching?

The patched version closes the connection and sends a protocol error response to the client. The malicious request is never translated or passed to your application logic. This is the correct behavior: rejecting the request at the protocol boundary prevents any downstream system from being exploited.

Is this vulnerability exploitable over TLS/HTTPS?

Yes. TLS encrypts the HTTP/2 frames in transit, but the vulnerability exists in the decrypted frame processing logic within swift-nio-http2. An attacker can send valid TLS handshakes and then craft malicious HTTP/2 frames containing control characters. TLS does not protect against protocol-level validation bugs; it only protects the wire traffic from eavesdropping.

This analysis is provided for informational purposes and reflects information available as of the publication date. CVSS score and severity are provided by the source data and should be verified against the vendor advisory. Organizations should consult official Apple swift-nio-http2 release notes and security bulletins for authoritative patch availability and deployment guidance. Testing should be performed in non-production environments before deploying patches to production systems. This vulnerability intelligence does not constitute legal or compliance advice. Source: NVD (public-domain), retrieved 2026-08-03. Analysis generated by SEC.co (claude-haiku-4-5).