{"id":"CVE-2026-50006","state":"PUBLISHED","title":"Anyquery: Arbitrary File Write (AFW) which could lead to Remote Code Execution (RCE) via Unrestricted ATTACH DATABASE in Server Mode","description":"Anyquery is an SQL query engine built on top of SQLite. Prior to 0.4.5, anyquery server forwards unauthenticated SQL from its MySQL-compatible server port to SQLite without restricting ATTACH DATABASE filesystem targets. A remote attacker can select any path writable by the Anyquery server process, cause SQLite to create a database file there, and place attacker-controlled table content in that file. This permits arbitrary file creation or overwrite, causing filesystem integrity loss and denial of service; remote code execution is possible only when another service interprets the written file or the process has a suitably privileged writable target. This issue is fixed in version 0.4.5.","publishedAt":"2026-09-14T19:56:39.502Z","updatedAt":"2026-09-15T19:32:05.351Z","severity":{"score":9.1,"label":"Critical","version":"3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:H","source":"GitHub_M"},"assigner":"GitHub_M","products":["julien040 anyquery"],"affected":[{"vendor":"julien040","product":"anyquery","versions":[{"version":"< 0.4.5","status":"affected"}]}],"references":["https://github.com/julien040/anyquery/security/advisories/GHSA-xrcf-6jh3-ggvx","https://github.com/julien040/anyquery/commit/27f84fc168310455eaf81ec4ba87eed20298670c","https://github.com/julien040/anyquery/releases/tag/0.4.5"],"weaknesses":["CWE-22","CWE-73","CWE-284","CWE-434","CWE-862"],"ingestedAt":"2026-10-29T20:12:16.098Z","source":{"repository":"CVEProject/cvelistV5","path":"cves/2026/50xxx/CVE-2026-50006.json","commit":"556c9d3a8cd17e218bb8e452ba7cd619a384ff47"},"raw":{"dataType":"CVE_RECORD","dataVersion":"5.2","cveMetadata":{"cveId":"CVE-2026-50006","state":"PUBLISHED","datePublished":"2026-09-14T19:56:39.502Z","dateUpdated":"2026-09-15T19:32:05.351Z","assignerShortName":"GitHub_M","assignerOrgId":"a0819718-46f1-4df5-94e2-005712e83aaa","dateReserved":"2026-06-02T22:46:02.578Z"},"containers":{"cna":{"title":"Anyquery: Arbitrary File Write (AFW) which could lead to Remote Code Execution (RCE) via Unrestricted ATTACH DATABASE in Server Mode","descriptions":[{"lang":"en","value":"Anyquery is an SQL query engine built on top of SQLite. Prior to 0.4.5, anyquery server forwards unauthenticated SQL from its MySQL-compatible server port to SQLite without restricting ATTACH DATABASE filesystem targets. A remote attacker can select any path writable by the Anyquery server process, cause SQLite to create a database file there, and place attacker-controlled table content in that file. This permits arbitrary file creation or overwrite, causing filesystem integrity loss and denial of service; remote code execution is possible only when another service interprets the written file or the process has a suitably privileged writable target. This issue is fixed in version 0.4.5."}],"affected":[{"vendor":"julien040","product":"anyquery","versions":[{"version":"< 0.4.5","status":"affected"}]}],"references":[{"url":"https://github.com/julien040/anyquery/security/advisories/GHSA-xrcf-6jh3-ggvx","name":"https://github.com/julien040/anyquery/security/advisories/GHSA-xrcf-6jh3-ggvx","tags":["x_refsource_CONFIRM"]},{"url":"https://github.com/julien040/anyquery/commit/27f84fc168310455eaf81ec4ba87eed20298670c","name":"https://github.com/julien040/anyquery/commit/27f84fc168310455eaf81ec4ba87eed20298670c","tags":["x_refsource_MISC"]},{"url":"https://github.com/julien040/anyquery/releases/tag/0.4.5","name":"https://github.com/julien040/anyquery/releases/tag/0.4.5","tags":["x_refsource_MISC"]}],"metrics":[{"cvssV3_1":{"attackComplexity":"LOW","attackVector":"NETWORK","availabilityImpact":"HIGH","baseScore":9.1,"baseSeverity":"CRITICAL","confidentialityImpact":"NONE","integrityImpact":"HIGH","privilegesRequired":"NONE","scope":"UNCHANGED","userInteraction":"NONE","vectorString":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:H","version":"3.1"}}],"problemTypes":[{"descriptions":[{"cweId":"CWE-22","lang":"en","description":"CWE-22: Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal')","type":"CWE"}]},{"descriptions":[{"cweId":"CWE-73","lang":"en","description":"CWE-73: External Control of File Name or Path","type":"CWE"}]},{"descriptions":[{"cweId":"CWE-284","lang":"en","description":"CWE-284: Improper Access Control","type":"CWE"}]},{"descriptions":[{"cweId":"CWE-434","lang":"en","description":"CWE-434: Unrestricted Upload of File with Dangerous Type","type":"CWE"}]},{"descriptions":[{"cweId":"CWE-862","lang":"en","description":"CWE-862: Missing Authorization","type":"CWE"}]}],"providerMetadata":{"shortName":"GitHub_M","orgId":"a0819718-46f1-4df5-94e2-005712e83aaa","dateUpdated":"2026-09-14T19:56:39.502Z"},"source":{"advisory":"GHSA-xrcf-6jh3-ggvx","discovery":"UNKNOWN"}},"adp":[{"title":"CISA ADP Vulnrichment","references":[{"url":"https://github.com/julien040/anyquery/security/advisories/GHSA-xrcf-6jh3-ggvx","tags":["exploit"]}],"metrics":[{"other":{"type":"ssvc","content":{"timestamp":"2026-09-15T19:31:47.618546Z","id":"CVE-2026-50006","options":[{"Exploitation":"poc"},{"Automatable":"yes"},{"Technical Impact":"total"}],"role":"CISA Coordinator","version":"2.0.3"}}}],"providerMetadata":{"shortName":"CISA-ADP","orgId":"134c704f-9b21-4f2e-91b3-4a467353bcc0","dateUpdated":"2026-09-15T19:32:05.351Z"}}]}}}