☠️
EXFILTRATING
DATA...
01010111 10110010 00101001 11000110 01101100 10011011 00010001 11100101 01000010 10101111
[ <-- BACK_TO_SEARCH ]
[ VENDOR STATS ]
SOON 🐛 CWE-444
👁️
Common Weakness Enumeration - Identifies the specific category of software weakness or flaw.

CVE-2024-47220

CVE-2024-47220 Supply Chain Attack in Ruby
📅 PUBLISHED: 2024-09-22 00:00 UTC 🔄 UPDATED: 2026-09-24 14:30 UTC
[ OFFICIAL PATCH DEPLOYED ↓ ] FIX: LIKELY — 2 independent sources confirm fix ⏳ CVSS score pending NVD analysis
[ DEFENSE PATCH ↓ ]
💣 PoC: None
👁️
Proof of Concept - Indicates if functional exploit code is publicly available, drastically increasing the risk of immediate attacks.
🎯 EPSS: <0.01%
👁️
<0.01% probability
<1× above the median CVE
Tier: LOW
30-day exploitation window · FIRST.org · updated daily
Patch available — upgrade to latest release
CVSS SEVERITY SCALE
9.0–10.0 CRITICAL
7.0–8.9 HIGH
4.0–6.9 MEDIUM
0.1–3.9 LOW
0.0 NONE
SOON
PENDING NVD
■ tracking this CVE ✓ independent patch confirmation ⧗ same-origin mirror (GHSA) ⚠ active exploitation verification policy →

Executive Summary

CVE-2024-47220 is an HTTP request smuggling vulnerability in the WEBrick HTTP server toolkit, which is bundled with Ruby. The flaw allows an attacker to bypass security controls and potentially access restricted resources by crafting a single HTTP request that is interpreted as two separate requests by the server. This is achieved by providing both a Content-Length and a Transfer-Encoding header, leading to a desynchronization between the front-end proxy (if any) and the WEBrick server. The vendor's position is that WEBrick should not be used in production, and no official patch has been released.

⚡ AUTOMATE YOUR CVE INTELLIGENCE

This record — and 170,000+ others — are available via the ValtersIT API. One endpoint replaces five: NVD + GitHub CVE + CISA KEV + EPSS + Nuclei + Exploit-DB, unified.

›Patch confidence — UNVERIFIED to CONFIRMED, cross-referenced NVD + RHSA + Debian
›Exploit & PoC — poc_status, poc_url, has_exploit. Not in NVD.
›Shodan dorks — ready-made queries to find exposed vulnerable systems
›Detection rules — YARA · Wazuh · Elastic (all plans) · Sigma (Pro)
›pending_fields — know exactly which of 7 fields NVD hasn't processed yet
›Free backfill — data incomplete when you paid? Re-check within 30 days = 0 credits
PAYG €0.08/lookup Standard €19/mo (was €29) · 5k credits Pro €65/mo (was €99) · 20k credits FOUNDING PRICE · LOCKED FOR LIFE · ENDS 31 DEC 2026
[ FROM €19/MO ]
Free sandbox key available
No signup required

Supply Chain & Package Security

This vulnerability affects the Ruby ecosystem, specifically the WEBrick library which is part of Ruby's standard library. Organizations using Ruby applications that rely on WEBrick in production are at risk. Since WEBrick is often used for development and testing, the supply chain risk is lower for production deployments, but any application inadvertently exposing WEBrick to untrusted networks is vulnerable.

CVSS Breakdown & Threat Level

  • CVSS Score: 5.3 (Medium)
  • Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:L/A:N
  • Attack Vector: Network
  • Attack Complexity: Low
  • Privileges Required: None
  • User Interaction: None
  • Scope: Unchanged
  • Confidentiality Impact: Low
  • Integrity Impact: Low
  • Availability Impact: None

The threat level is medium due to the low complexity and network-based attack vector, but the impact is limited to potential access to restricted resources and minor data manipulation.

Deep Dive & Mechanics

The vulnerability exploits the HTTP request smuggling technique. When WEBrick receives a request with both Content-Length and Transfer-Encoding headers, it processes the request body based on one header while a downstream proxy might use the other. This desynchronization allows an attacker to "smuggle" a second request within the body of the first.

For example, an attacker sends a POST /user HTTP/1.1 request with a Content-Length header indicating a long body, and a Transfer-Encoding: chunked header. The body contains a complete GET /admin HTTP/1.1 request. WEBrick might interpret the entire body as part of the first request, while a proxy sees the chunked encoding and treats the embedded request as a separate, legitimate request to /admin.

This can lead to:

  • Bypassing access controls (e.g., accessing /admin without authentication).
  • Cache poisoning (if a proxy caches the smuggled response).
  • Session hijacking in certain configurations.

Vulnerable vs. Patched Code

Vulnerable Code (WEBrick <= 1.8.1): The vulnerable code is in the HTTP request parsing logic. The server does not properly handle the case where both Content-Length and Transfer-Encoding headers are present. It may process the body based on Content-Length while ignoring Transfer-Encoding, or vice versa, leading to smuggling.

# Simplified vulnerable logic
def parse_request
  if headers['transfer-encoding']
    # Process chunked encoding
  elsif headers['content-length']
    # Process fixed length
  end
  # No check for both headers present
end

Patched Code (Not available): The vendor recommends not using WEBrick in production. A proper fix would involve rejecting requests that contain both headers, or strictly adhering to RFC 7230 which states that if both are present, Transfer-Encoding should take precedence and Content-Length should be ignored.

# Hypothetical patched logic
def parse_request
  if headers['transfer-encoding'] && headers['content-length']
    # Reject or ignore Content-Length per RFC 7230
    headers.delete('content-length')
  end
  # Continue processing
end

Exploitation & Lab Setup

Red Team (Offensive)

Lab Setup:

  1. Install Ruby and WEBrick (default with Ruby).
  2. Create a simple WEBrick server with a protected /admin endpoint.
  3. Use a tool like netcat or curl to send a crafted request.

Exploit Example:

# Crafted request using netcat
printf "POST /user HTTP/1.1\r\nHost: target.com\r\nContent-Length: 56\r\nTransfer-Encoding: chunked\r\n\r\n0\r\n\r\nGET /admin HTTP/1.1\r\nHost: target.com\r\n\r\n" | nc target.com 8080

Explanation:

  • The first request (POST /user) has both headers.
  • The body contains a complete GET /admin request.
  • WEBrick may process the body as part of the POST, while a proxy sees the chunked encoding and treats the embedded request as a separate request to /admin.

Blue Team (Defensive)

Detection:

  • Monitor for requests containing both Content-Length and Transfer-Encoding headers.
  • Use WAF rules to block such requests.
  • Log and alert on unusual request patterns.

Mitigation:

  • Replace WEBrick with a production-ready server like Puma, Unicorn, or Passenger.
  • If WEBrick must be used, place it behind a reverse proxy that normalizes headers (e.g., Nginx with proxy_set_header).
  • Implement strict input validation and header sanitization.

Indicators of Compromise (IOCs)

  • Network IOCs:

    • HTTP requests containing both Content-Length and Transfer-Encoding headers.
    • Requests with unusual body content that includes complete HTTP requests.
    • Multiple requests from the same source to different endpoints in quick succession.
  • Log IOCs:

    • WEBrick access logs showing requests with unexpected body lengths.
    • Error logs indicating parsing issues or malformed requests.
  • File IOCs:

    • No specific file-based IOCs.

Detection Engineering

YARA Rule

rule HTTP_Request_Smuggling_CVE_2024_47220 {
    meta:
        description = "Detects HTTP request smuggling attempts targeting WEBrick"
        author = "Valters IT"
        date = "2024-10-27"
        reference = "CVE-2024-47220"
    strings:
        $content_length = "Content-Length:" nocase
        $transfer_encoding = "Transfer-Encoding:" nocase
        $http_request = /GET|POST|PUT|DELETE|HEAD|OPTIONS|PATCH/ nocase
    condition:
        all of ($content_length, $transfer_encoding) and #http_request > 1
}

Sigma Rule

title: HTTP Request Smuggling - CVE-2024-47220
id: 12345678-1234-1234-1234-123456789012
status: experimental
description: Detects HTTP requests with both Content-Length and Transfer-Encoding headers
author: Valters IT
date: 2024-10-27
logsource:
    category: webserver
    product: ruby
detection:
    selection:
        http.request.headers|contains:
            - 'Content-Length:'
            - 'Transfer-Encoding:'
    condition: selection
falsepositives:
    - Legitimate use of both headers in rare cases (e.g., HTTP/1.0 to HTTP/1.1 conversion)
level: high

Suricata Rule

alert http any any -> any any (msg:"CVE-2024-47220 HTTP Request Smuggling Attempt"; flow:to_server; content:"Content-Length:"; http_header; content:"Transfer-Encoding:"; http_header; classtype:attempted-recon; sid:1000001; rev:1;)

Remediation & Mitigation

  1. Immediate Action: Replace WEBrick with a production-ready HTTP server (e.g., Puma, Unicorn, Passenger).
  2. Short-term Mitigation: If WEBrick must be used, place it behind a reverse proxy (e.g., Nginx, Apache) that normalizes headers and rejects ambiguous requests.
  3. Long-term Fix: Monitor Ruby's official repository for a patch. Until then, follow the vendor's advice and avoid using WEBrick in production.
  4. Detection: Implement the provided YARA, Sigma, and Suricata rules to detect exploitation attempts.
  5. Monitoring: Enable detailed logging on WEBrick and any front-end proxies to identify suspicious request patterns.

Valters IT
DevSecOps & Cyber Threat Intelligence Expert

◈ SOURCE Analysis & enrichment: valtersit.com/cve/CVE-2024-47220/ · CVE data: NVD/MITRE (public domain) · © 2026 ValtersIT Hub
>_ SYSTEM_CORE: INTEL_ACTIVE
90% TEAM-CURATED // 10% AUTOMATED INGESTION.
ALL PATCH REFERENCES AND VERSION DATA SOURCED FROM NVD + OSV OFFICIAL REGISTRIES.