/

CVE-2026-75915

Severity:

HIGH RISK

(7.5)

Environment Exposure (CWE-200) in CodeWhale js_execution

CVE-2026-75915

Deferred

Vulnerability type

Category:

Information Exposure

CWE:

CWE-200

Impact:

Credential and Sensitive Information Disclosure

Severity:

HIGH RISK

(7.5)

CVSS version:

3.1

Catch this CVE while code is being written

Detect vulnerable code directly in pull requests, so CVEs are fixed before merge.

Summary

CodeWhale's js_execution tool may pass parent-process environment variables into spawned Node.js processes without scrubbing them. Malicious JavaScript executed through the tool could read process.env and expose API keys, cloud credentials, or authentication tokens to the model context.

Affected context

The vulnerability affects CodeWhale deployments that use the js_execution tool to run JavaScript in a child Node.js process while inheriting the parent process environment. Risk is higher when sensitive credentials or tokens are present in environment variables and untrusted or insufficiently constrained code can reach the execution tool.

Exploit preconditions

  • Attack surface: The CodeWhale js_execution tool and its JavaScript runtime - Required access: Ability to submit or influence JavaScript executed by the

tool

  • Trigger point: Creation of a Node.js process followed by access to

process.env

  • Why exploitation is possible: Parent environment variables are inherited

without adequate filtering, making sensitive values available to executed

code

Why this happens

The underlying issue is failure to establish a minimized environment for a child process before executing potentially untrusted JavaScript. Inherited process variables can contain secrets unrelated to the task, and exposing them to the script creates an unintended information flow. This maps to CWE-200, Information Exposure, because sensitive data becomes accessible through a component that does not require it.

Potential impact

  • API keys may be disclosed
  • Cloud credentials could be exposed and misused
  • Authentication tokens may be revealed
  • Downstream services or accounts could be accessed
  • Sensitive environment metadata may be returned to the model context

General mitigation guidance

Mitigation generally focuses on reducing trust in executed code and limiting the data available to child processes. Common defensive patterns include constructing an explicit allowlist-based environment rather than inheriting the parent environment, keeping secrets out of process variables where practical, isolating JavaScript execution, and applying least-privilege identities and short-lived credentials. Output and tool boundaries can also be designed to prevent sensitive values from being returned to the model context.

How teams detect issues like this

Detection can include static analysis for child-process creation that inherits unrestricted environments, review of JavaScript execution paths, and checks for direct access to process.env in untrusted-code contexts. Code review should examine whether environment variables are explicitly allowlisted and whether credentials are available to execution workers. Runtime monitoring and policy enforcement can flag secret-like values in tool outputs or unexpected access to sensitive environment names.

Sources

SourceLink
github.comgithub.com/Hmbown/CodeWhale/commit/26de44a8bd5051f8f944ea60b2c37ae1d2b7d25e
github.comgithub.com/Hmbown/CodeWhale/security/advisories/GHSA-h539-c7r8-3xq4
vulncheck.comvulncheck.com/advisories/codewhale-before-environment-variable-leak-via-js-execution

Frequently asked

questions

It may be exploitable through any remotely reachable interface that permits an

attacker to submit or influence JavaScript executed by js_execution. The

exact scope depends on how the tool is exposed and authenticated.

An attacker generally needs the ability to invoke the tool or control code

that it executes. They also need the target process to contain useful

secrets in inherited environment variables.

Spawn execution workers with a minimal, explicit environment allowlist and

prevent untrusted JavaScript from accessing credentials or other sensitive

process data.

Treat tool-executed code as untrusted, isolate it with least privilege, avoid

placing long-lived secrets in inherited environments, and enforce automated

checks for unrestricted environment inheritance.

Find out what's already
exploitable in your codebase.