Skip to main content

ApostropheCMS CLI CVE-2026-42853

| EUVDEUVD-2026-36565 MEDIUM
OS Command Injection (CWE-78)
2026-05-14 https://github.com/apostrophecms/apostrophe GHSA-hcwq-x9fw-8cfq
6.5
CVSS 3.1 · Vendor: https://github.com/apostrophecms/apostrophe
View

Attack ChainAIDerived

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

  1. Recon
    Deliver malicious password payload to developer
  2. Delivery
    Developer executes apos create command
  3. Exploit
    Interactive prompt requests password input
  4. Install
    Developer enters or pastes attacker-controlled payload
  5. C2
    Payload parsed into exec() without escaping
  6. Execute
    Shell interprets metacharacters (;, &&, $())
  7. Impact
    Arbitrary command executed with developer's privileges
  8. Step 8
    Attacker achieves code execution and potential privilege escalation

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V1 - Encoding and Sanitization OS command sanitization, avoid shell exec
MITRE ATT&CK

2 techniques across 1 tactic: Execution

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

Exploitation Conditions

Exploitation requires the following specific, concrete conditions: (1) @apostrophecms/cli package installed and the apos create command executed; (2) The attacker must influence the password input during the interactive prompt - this occurs either via direct user interaction (social engineering, malicious documentation) or by providing malicious input to an automated script that runs 'apos create' non-interactively; (3) The user running 'apos create' must have sufficient privileges to execute arbitrary commands (typically any local user can do this, but impact depends on that user's privilege level - Docker and sudo group membership shown in PoC amplifies impact); (4) No input validation, sanitization, or escaping is applied to response.pw before shell execution. Limiting factors: Attack is LOCAL ONLY (AV:L), not remotely exploitable over network; HIGH PRIVILEGE context (PR:H) suggests the vulnerability is most impactful when the user running CLI has elevated group memberships; USER INTERACTION (UI:R) required to influence password prompt input, either through direct instruction or script parameter injection. Default configuration of the package is vulnerable - no special flags or configuration settings disable the vulnerability.

Impact

CVSS 6.5 (AV:L/AC:L/PR:H/UI:R) indicates local attack vector with high privileges required and user interaction necessary - this significantly limits real-world exposure compared to network-based vectors. However, the attack surface is developers running 'apos create' commands during project setup, often in CI/CD pipelines or shared development environments where privilege levels may be elevated (as evidenced by POC showing sudo and docker group membership). EPSS score not provided in input. Exploitation requires either social engineering to convince a user to enter malicious input, or automation scripts that accept password input from untrusted sources. The combination of CVSS constraints (PR:H, UI:R) and local-only attack vector means this is NOT an immediate remote mass-exploitation risk, but poses significant insider threat and supply-chain attack risk in development environments. No KEV status or active exploitation reports provided; however, publicly available PoC reduces exploitation barriers. The fact that 'all current versions' are listed as vulnerable without a confirmed fixed version suggests patch availability may be pending or limited.

Exploit ScenarioDerived

A developer is instructed to create a new ApostropheCMS project using 'apos create mysite'. When prompted for the admin password, instead of entering a legitimate password, the attacker (via social engineering, malicious documentation, or compromised tutorial) instructs the developer to paste a payload like '; id > /tmp/apos_rce_proof.txt; echo '. The command is executed in the developer's shell context with their privileges (potentially including sudo and docker group membership), allowing file creation, credential theft, or system compromise.

This Month Plan within 30 days. Why: MEDIUM severity (CVSS 4.0-6.9).
No patch listed yet 0.0% exploitation probability (EPSS)

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

Alert me

AnalysisAIv1 – May 14, 2026

Command injection in @apostrophecms/cli apos create command allows arbitrary command execution when a user supplies specially crafted input during the interactive password prompt. The vulnerability exists in lib/commands/create.js line 186, where user-supplied password input is passed directly into a shell exec() call without sanitization or escaping, enabling attackers to inject shell metacharacters (;, &&, $()) to execute arbitrary commands with the privileges of the user running the CLI. Exploitation requires user interaction (UI:R) and high privilege context (PR:H), but publicly available proof-of-concept demonstrates successful arbitrary code execution on Ubuntu systems with Node.js.

RemediationAI

No vendor-released patch version has been confirmed at the time of analysis. The suggested fix is to replace child_process.exec() with execFileSync() or a similar argument-separating function that prevents shell injection. Developers should immediately audit any automated deployment scripts that invoke 'apos create' with programmatic password input and migrate them to use argument passing rather than shell string interpolation. As a temporary compensating control, restrict the apos create command to trusted administrators only and avoid running it in automated contexts with untrusted input sources. Code review of lib/commands/create.js line 186 should verify that the fix implements execFile() with arguments passed as an array rather than a concatenated shell string. Organizations with strict password policies should ensure no password input is logged or stored in shell history during project creation. Monitor npm advisory channels and the ApostropheCMS GitHub security advisory page (https://github.com/apostrophecms/apostrophe/security/advisories/GHSA-hcwq-x9fw-8cfq) for patch availability.

Affected VersionsENISA

@apostrophecms/cli ≤ 3.6.0

Affected Packages

npm @apostrophecms/cli no fix
euvd apostrophecms_cli no fix

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 2 packages in npm, euvd

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

Technical ContextAI · show details

The @apostrophecms/cli package uses Node.js child_process.exec() to invoke shell commands during project creation. The vulnerability stems from CWE-78 (Improper Neutralization of Special Elements used in an OS Command) - specifically, the apos create command collects a password via an interactive prompt using the 'prompts' library, then embeds the raw response.pw value directly into a template string passed to exec() without any escaping or validation. The shell interprets this string, allowing an attacker to break out of the intended echo command using metacharacters. The recommended fix involves replacing exec() with execFile() (or execFileSync()), which separates command arguments from the shell interpretation layer, preventing injection.

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/apostrophecms/apostrophe) PRIMARY 6.5 MEDIUM
AV:L/AC:L/PR:H/UI:R/S:U/C:H/I:H/A:H

Primary rating from Vendor (https://github.com/apostrophecms/apostrophe) · only source for this CVE.

CVSS VectorVendor: https://github.com/apostrophecms/apostrophe

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

DescriptionCVE.org

Summary

The @apostrophecms/cli package contains a command injection vulnerability in the apos create command. User-supplied input from the password prompt is embedded directly into a shell command without proper sanitization or escaping. This allows execution of arbitrary commands on the host system.

━━━━━━━━━━━━━━━━━━━━━━

Details

Vulnerable file: lib/commands/create.js Location: Line 186

The CLI collects a password using an interactive prompt and passes it directly into a shell command.

Vulnerable code:

const response = await prompts({ type: 'password', name: 'pw', message: '🔏 Please enter a password:' });

exec(echo "${response.pw}" | ${createUserCommand});

The value of response.pw is not validated, sanitized, or escaped before being used in exec().

This allows shell metacharacters such as ;, &&, and $() to break out of the intended command and execute arbitrary commands.

━━━━━━━━━━━━━━━━━━━━━━

Steps to Reproduce

  1. Install the CLI

npm install -g @apostrophecms/cli

  1. Create a new project

mkdir testproject && cd testproject apos create mysite 3)When prompted for the admin password, enter "; id > /tmp/apos_rce_proof.txt; echo " 4)Verify command execution cat /tmp/apos_rce_proof.txt

━━━━━━━━━━━━━━━━━━━━━━

Proof of Concept Output

uid=1000(vboxuser) gid=1000(vboxuser) groups=1000(vboxuser),27(sudo),984(docker)

This confirms arbitrary command execution with the privileges of the user running the CLI.

━━━━━━━━━━━━━━━━━━━━━━

Impact

Arbitrary command execution on the developer’s machine Execution occurs with the privileges of the user running the CLI

This can lead to:

File modification or deletion Credential exposure System compromise depending on user privileges

An attacker can exploit this by influencing the password input (for example, through social engineering, malicious documentation, or compromised automation scripts).

The proof-of-concept shows execution under a user belonging to privileged groups such as sudo and docker, which may allow further privilege escalation depending on system configuration.

━━━━━━━━━━━━━━━━━━━━━━

Suggested Fix

Avoid using exec() with user-controlled input.

Use execFile() instead:

const { execFileSync } = require('child_process');

execFileSync('node', [appJsPath, userTask, 'admin', 'admin'], { input: response.pw + '\n' });

━━━━━━━━━━━━━━━━━━━━━━

Affected Version

All current versions of @apostrophecms/cli

━━━━━━━━━━━━━━━━━━━━━━

Tested On

Ubuntu 22.04 Node.js v18.19.1

━━━━━━━━━━━━━━━━━━━━━━

CWE

CWE-78 - Improper Neutralization of Special Elements used in an OS Command

━━━━━━━━━━━━━━━━━━━━━━

Threat Intelligence Overview

EPSS Score
0.0%
Top 92% 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 MEDIUM
CISA KEV No
Public POC No
EPSS 0.0%
Patch available No
Active threat No
Deciding rule
MEDIUM severity (CVSS 4.0-6.9)
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
Defer
Exploitation· derived
None
System Exposure· derived
Small
Automatable· derived
No
Human Impact· derived
Medium

Priority Score

32
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +32
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.

Privilege escalation occurs when an attacker leverages flaws in access control mechanisms to gain permissions beyond what they were originally granted.

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

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