{"schemaVersion":1,"url":"https://cve.openhack.com/cve/CVE-2026-40871","id":"CVE-2026-40871","title":"mailcow: dockerized vulnerable to Second Order SQL Injection in quarantine category via API","description":"mailcow: dockerized is an open source groupware/email suite based on docker. Versions prior to 2026-03b have a second-order SQL injection vulnerability in the quarantine_category field via the Mailcow API. The /api/v1/add/mailbox endpoint stores quarantine_category without validation or sanitization. This value is later used by quarantine_notify.py, which constructs SQL queries using unsafe % stri","descriptionLong":"mailcow: dockerized is an open source groupware/email suite based on docker. Versions prior to 2026-03b have a second-order SQL injection vulnerability in the quarantine_category field via the Mailcow API. The /api/v1/add/mailbox endpoint stores quarantine_category without validation or sanitization. This value is later used by quarantine_notify.py, which constructs SQL queries using unsafe % string formatting instead of parameterized queries. This results in a delayed (second-order) SQL injection when the quarantine notification job executes, allowing an attacker to inject arbitrary SQL. Using a UNION SELECT, sensitive data (e.g., admin credentials) can be exfiltrated and rendered inside quarantine notification emails. Version 2026-03b fixes the vulnerability.","published":"2026-04-21T19:12:52.781Z","updated":"2026-10-28T02:30:42.514116902Z","reserved":"2026-04-15T15:57:41.718Z","status":"Deferred","rejected":false,"assigner":"GitHub_M","metric":{"version":"3.1","score":7.2,"vector":"CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:H/I:H/A:H","rating":"high","source":"GitHub_M"},"metrics":[{"version":"3.1","score":7.2,"vector":"CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:H/I:H/A:H","rating":"high","source":"GitHub_M"},{"version":"3.1","score":7.2,"vector":"CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:H/I:H/A:H","rating":"high","source":"github.com"},{"version":"3.1","score":7.2,"vector":"CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:H/I:H/A:H","rating":"high","source":"OSV"}],"rating":"high","products":["mailcow-dockerized"],"affectedProducts":[{"vendor":"mailcow","product":"mailcow-dockerized","defaultStatus":null,"versions":[{"version":"< 2026-03b","status":"affected"}],"platforms":[]}],"packages":[],"cwes":["CWE-20","CWE-89","CWE-116","CWE-564"],"aliases":["GHSA-r8fq-wrfm-cj2q"],"references":[{"url":"https://github.com/mailcow/mailcow-dockerized/security/advisories/GHSA-r8fq-wrfm-cj2q","tags":["x_refsource_CONFIRM","exploit","advisory"]},{"url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/40xxx/CVE-2026-40871.json","tags":["advisory"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2026-40871","tags":["advisory"]}],"patchReferenced":false,"fixAvailable":false,"exploitReferenced":true,"kev":false,"kevAdded":null,"kevDue":null,"kevEntry":null,"ssvc":{"exploitation":"poc","automatable":"no","technicalImpact":"total"},"epss":0.08889,"epssPercentile":0.95331,"sources":[{"name":"CVE List","url":"https://www.cve.org/CVERecord?id=CVE-2026-40871","ok":true},{"name":"NVD","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-40871","ok":true,"note":"Deferred"},{"name":"OSV","url":"https://osv.dev/vulnerability/CVE-2026-40871","ok":true,"note":"0 packages"},{"name":"CISA KEV","url":"https://www.cisa.gov/known-exploited-vulnerabilities-catalog","ok":true,"note":"not listed"},{"name":"EPSS","url":"https://api.first.org/data/v1/epss?cve=CVE-2026-40871","ok":true,"note":"scored 2026-11-19"}],"aiTitle":false,"tech":[],"critical":[],"attention":null}