Description
@pensar/apex <= 0.0.58 is vulnerable to OS command injection via the smart_enumerate tool. The createSmartEnumerateTool() function in src/core/agent/tools.ts constructs a shell command by concatenating unsanitized values from the extensions array and url parameter into a string passed to Node.js child_process.exec(). Because exec() spawns a shell, shell metacharacters in those values are interpreted by the host shell, resulting in arbitrary OS command execution with the privileges of the running process. NOTE: this is disputed by the Supplier because the report is about intended behavior, as explained in the Security Policy of the pensarai/apex GitHub repo.
Published: 2026-05-27
Score: 8.8 High
EPSS: 2.4% Low
KEV: No
Impact: n/a
Action: n/a
AI Analysis

Impact

@pensar/apex versions 0.0.58 and earlier contain a command injection flaw in the smart_enumerate tool. The createSmartEnumerateTool() function builds a shell command by concatenating unsanitized values from an extensions array and a url parameter, then passes the string to Node.js child_process.exec(). Because exec() spawns a shell, any shell metacharacters in those values are interpreted, allowing an attacker to execute arbitrary commands with the privileges of the running process.

Affected Systems

The vulnerability affects the @pensar/apex package for all releases up to and including v0.0.58. Any installation that uses this package and the smart_enumerate tool is potentially exposed; no other vendors or products are listed.

Risk and Exploitability

The CVSS score is 8.8, indicating high severity. EPSS score is 2%, indicating a low probability of exploitation, and the issue is not listed in CISA's KEV catalog. The exploit requires control over the extensions array or url parameter used by the tool. If the tool is exposed to an attacker—whether through a local user, a compromised process, or a remote request—an attacker can inject shell metacharacters to run arbitrary OS commands. The exact attack vector is not explicitly described in the advisory, but the function’s use of exec() implies that any user supplied input can be leveraged if the tool is reachable.

Generated by OpenCVE AI on June 16, 2026 at 09:24 UTC.

Remediation

No vendor fix or workaround currently provided.

OpenCVE Recommended Actions

  • Upgrade @pensar/apex to version 0.0.59 or newer to remove the vulnerable code.
  • If an upgrade is infeasible, disable or remove the smart_enumerate tool from the deployment so that no unsanitized command execution path remains.
  • Limit the scope of input values by implementing input validation or sanitization on the extensions array and url parameter before they are passed to exec().
  • If the tool must remain in use, apply stricter runtime permissions to the process so that it runs with the least privileges necessary for operation.

Generated by OpenCVE AI on June 16, 2026 at 09:24 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories yet.

History

Tue, 16 Jun 2026 09:45:00 +0000

Type Values Removed Values Added
Title OS Command Injection Vulnerability in @pensar/apex Smart Enumerate Tool

Wed, 03 Jun 2026 11:15:00 +0000

Type Values Removed Values Added
Title OS Command Injection via Unsanitized Parameters in @pensar/apex's smart_enumerate Tool

Wed, 03 Jun 2026 04:00:00 +0000

Type Values Removed Values Added
Description @pensar/apex <= 0.0.58 is vulnerable to OS command injection via the smart_enumerate tool. The createSmartEnumerateTool() function in src/core/agent/tools.ts constructs a shell command by concatenating unsanitized values from the extensions array and url parameter into a string passed to Node.js child_process.exec(). Because exec() spawns a shell, shell metacharacters in those values are interpreted by the host shell, resulting in arbitrary OS command execution with the privileges of the running process. @pensar/apex <= 0.0.58 is vulnerable to OS command injection via the smart_enumerate tool. The createSmartEnumerateTool() function in src/core/agent/tools.ts constructs a shell command by concatenating unsanitized values from the extensions array and url parameter into a string passed to Node.js child_process.exec(). Because exec() spawns a shell, shell metacharacters in those values are interpreted by the host shell, resulting in arbitrary OS command execution with the privileges of the running process. NOTE: this is disputed by the Supplier because the report is about intended behavior, as explained in the Security Policy of the pensarai/apex GitHub repo.
References

Sat, 30 May 2026 23:00:00 +0000

Type Values Removed Values Added
First Time appeared Pensar
Pensar apex
Vendors & Products Pensar
Pensar apex

Fri, 29 May 2026 17:30:00 +0000

Type Values Removed Values Added
Metrics ssvc

{'options': {'Automatable': 'no', 'Exploitation': 'none', 'Technical Impact': 'total'}, 'version': '2.0.3'}


Wed, 27 May 2026 16:15:00 +0000

Type Values Removed Values Added
Title OS Command Injection via Unsanitized Parameters in @pensar/apex's smart_enumerate Tool
Weaknesses CWE-78

Wed, 27 May 2026 14:15:00 +0000

Type Values Removed Values Added
Description @pensar/apex <= 0.0.58 is vulnerable to OS command injection via the smart_enumerate tool. The createSmartEnumerateTool() function in src/core/agent/tools.ts constructs a shell command by concatenating unsanitized values from the extensions array and url parameter into a string passed to Node.js child_process.exec(). Because exec() spawns a shell, shell metacharacters in those values are interpreted by the host shell, resulting in arbitrary OS command execution with the privileges of the running process.
References
Metrics cvssV3_1

{'score': 8.8, 'vector': 'CVSS:3.1/AC:L/AV:N/A:H/C:H/I:H/PR:N/S:U/UI:R'}


cve-icon MITRE

Status: PUBLISHED

Assigner: mitre

Published:

Updated: 2026-06-03T03:41:20.766Z

Reserved: 2026-04-06T00:00:00.000Z

Link: CVE-2026-36044

cve-icon Vulnrichment

Updated: 2026-05-29T15:36:34.265Z

cve-icon NVD

Status : Deferred

Published: 2026-05-27T14:16:45.143

Modified: 2026-06-03T04:17:06.500

Link: CVE-2026-36044

cve-icon Redhat

No data.

cve-icon OpenCVE Enrichment

Updated: 2026-06-16T09:30:15Z

Weaknesses
  • CWE-78

    Improper Neutralization of Special Elements used in an OS Command ('OS Command Injection')