Führe statische Analyse (SAST) auf der Codebasis aus und suche im Datenfluss nach dem unsicheren Muster.
Inconsistent Interpretation of HTTP Requests ('HTTP Request/Response Smuggling')
This weakness occurs when a proxy, firewall, or other intermediary HTTP agent interprets a malformed HTTP request or response differently than the final destination server or client. This…
What is CWE-444?
Real-world CVEs caused by CWE-444
-
SSL/TLS-capable proxy allows HTTP smuggling when used in tandem with HTTP/1.0 services, due to inconsistent interpretation and input sanitization of HTTP messages within the body of another message
-
Chain: caching proxy server has improper input validation (CWE-20) of headers, allowing HTTP response smuggling (CWE-444) using an "LF line ending"
-
Node.js platform allows request smuggling via two Transfer-Encoding headers
-
Web servers allow request smuggling via inconsistent HTTP headers.
-
HTTP server allows request smuggling with both a "Transfer-Encoding: chunked" header and a Content-Length header
-
HTTP server allows request smuggling with both a "Transfer-Encoding: chunked" header and a Content-Length header
Angreiferpfad Schritt für Schritt
- 1
In the following example, a malformed HTTP request is sent to a website that includes a proxy server and a web server with the intent of poisoning the cache to associate one webpage with another malicious webpage.
- 2
When this request is sent to the proxy server, the proxy server parses the first four lines of the POST request and encounters the two "Content-Length" headers. The proxy server ignores the first header, so it assumes the request has a body of length 54 bytes. Therefore, it treats the data in the next three lines that contain exactly 54 bytes as the first request's body:
- 3
The proxy then parses the remaining bytes, which it treats as the client's second request:
- 4
The original request is forwarded by the proxy server to the web server. Unlike the proxy, the web server uses the first "Content-Length" header and considers that the first POST request has no body.
- 5
Because the web server has assumed the original POST request was length 0, it parses the second request that follows, i.e. for GET /poison.html:
Vulnerable code
In the following example, a malformed HTTP request is sent to a website that includes a proxy server and a web server with the intent of poisoning the cache to associate one webpage with another malicious webpage.
POST http://www.website.com/foobar.html HTTP/1.1
Host: www.website.com
Connection: Keep-Alive
Content-Type: application/x-www-form-urlencoded
Content-Length: 0
Content-Length: 54
GET /poison.html HTTP/1.1
Host: www.website.com
Bla: GET http://www.website.com/page_to_poison.html HTTP/1.1
Host: www.website.com
Connection: Keep-Alive In the following example, a malformed HTTP request is sent to a website that includes a proxy server and a web server with the intent of poisoning the cache to associate one webpage with another malicious webpage.
POST http://www.website.com/foobar.html HTTP/1.1
Host: www.website.com
Connection: Keep-Alive
Content-Type: application/x-www-form-urlencoded
Content-Length: 0
Content-Length: 54
GET /poison.html HTTP/1.1
Host: www.website.com
Bla: GET http://www.website.com/page_to_poison.html HTTP/1.1
Host: www.website.com
Connection: Keep-Alive Secure Java
Additionally, if a web application includes a Java servlet for processing requests, the servlet can check for multiple "Content-Length" headers and if they are found the servlet can return an error response thereby preventing the poison page to be cached, as shown below.
protected void processRequest(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
```
// Set up response writer object*
...
try {
```
```
// check for multiple content length headers*
Enumeration contentLengthHeaders = request.getHeaders("Content-Length");
int count = 0;
while (contentLengthHeaders.hasMoreElements()) {
```
count++;
}
if (count > 1) {
```
// output error response* }
else {
```
```
// process request* }
} catch (Exception ex) {...}} How to prevent CWE-444
- Implementation Use a web server that employs a strict HTTP parsing procedure, such as Apache [REF-433].
- Implementation Use only SSL communication.
- Implementation Terminate the client session after each request.
- System Configuration Turn all pages to non-cacheable.
How to detect CWE-444
Führe dynamische Application-Security-Tests gegen den Live-Endpoint aus.
Beobachte Runtime-Logs auf ungewöhnliche Exception-Traces, fehlerhafte Eingaben oder Versuche, Autorisierung zu umgehen.
Code Review: Markiere jeden neuen Code, der Eingaben von dieser Oberfläche ohne validierte Framework-Helper verarbeitet.
Plexicus erkennt CWE-444 automatisch und öffnet in unter 60 Sekunden einen Fix-PR.
Codex Remedium scannt jeden Commit, identifiziert genau diese Schwachstelle und liefert einen reviewer-ready Pull Request mit dem Patch. Keine Tickets. Keine Hand-offs.
Frequently asked questions
Was ist CWE-444?
This weakness occurs when a proxy, firewall, or other intermediary HTTP agent interprets a malformed HTTP request or response differently than the final destination server or client. This inconsistency allows an attacker to craft messages that bypass the intermediary's security checks.
Wie gravierend ist CWE-444?
MITRE hat für diese Schwachstelle keine Exploit-Wahrscheinlichkeit veröffentlicht. Behandle sie als mittlere Auswirkung, bis dein Threat Model anderes belegt.
Welche Sprachen oder Plattformen sind von CWE-444 betroffen?
MITRE lists the following affected platforms: Web Based.
Wie kann ich CWE-444 verhindern?
Use a web server that employs a strict HTTP parsing procedure, such as Apache [REF-433]. Use only SSL communication.
Wie erkennt und behebt Plexicus CWE-444?
Die SAST-Engine von Plexicus erkennt die Datenfluss-Signatur von CWE-444 bei jedem Commit. Bei einem Treffer öffnet unser Codex-Remedium-Agent einen Fix-PR mit korrigiertem Code, Tests und einer einzeiligen Zusammenfassung für den Reviewer.
Wo erfahre ich mehr über CWE-444?
MITRE veröffentlicht die kanonische Definition unter https://cwe.mitre.org/data/definitions/444.html. Für ergänzende Hinweise kannst du auch die OWASP- und NIST-Dokumentation heranziehen.
Weaknesses related to CWE-444
Interpretation Conflict
An interpretation conflict occurs when two systems process the same data or sequence of events differently, leading one system to make…
Improper Neutralization of CRLF Sequences in HTTP Headers ('HTTP Request/Response Splitting')
This vulnerability occurs when an application accepts user-supplied data and includes it directly in HTTP headers without properly…
Misinterpretation of Input
This vulnerability occurs when software incorrectly interprets or processes input data, leading to unintended and potentially harmful…
Incomplete Model of Endpoint Features
This vulnerability occurs when a security product, proxy, or monitoring system sits between endpoints but lacks a full understanding of…
Null Byte Interaction Error (Poison Null Byte)
This vulnerability occurs when software incorrectly processes null bytes (NUL characters) as data moves between different systems or…
Trusting HTTP Permission Methods on the Server Side
This vulnerability occurs when a server incorrectly assumes that HTTP GET requests are always safe and cannot change server-side data.…
Improper Neutralization of Invalid Characters in Identifiers in Web Pages
This vulnerability occurs when an application fails to properly filter or escape invalid characters within web identifiers like HTML tag…
Further reading
- MITRE — offizielle CWE-444 https://cwe.mitre.org/data/definitions/444.html
- HTTP Request Smuggling https://www.cgisecurity.com/lib/HTTP-Request-Smuggling.pdf
- HTTP Response Smuggling http://projects.webappsec.org/w/page/13246930/HTTP%20Response%20Smuggling
- HTTP Request Smuggling: Complete Guide to Attack Types and Prevention https://brightsec.com/blog/http-request-smuggling-hrs/
- A Pentester's Guide to HTTP Request Smuggling https://www.cobalt.io/blog/a-pentesters-guide-to-http-request-smuggling
- HTTP Desync Attacks in the Wild and How to Defend Against Them https://www.imperva.com/blog/archive/http-desync-attacks-and-defence-methods/
- HTTP Desync Attacks: Request Smuggling Reborn https://portswigger.net/research/http-desync-attacks-request-smuggling-reborn
Schluss mit dem Bezahlen pro Entwickler.
Schließ den Kreislauf.
Plexicus ist die KI-native ASPM, die scannt, filtert, fixt, pentestet und erklärt — autonom. Unbegrenzte Entwickler, unbegrenzte Repos, Fair-Use-KI-Aktionen. Echter kostenloser Tarif, €269/mo jährlich, wenn du bereit bist.