Severity by source
AV:L/AC:H/PR:N/UI:R/S:C/C:H/I:H/A:H
Primary rating from GitHub Advisory · only source for this CVE.
CVSS VectorGitHub Advisory
CVSS:3.1/AV:L/AC:H/PR:N/UI:R/S:C/C:H/I:H/A:H
Lifecycle Timeline
6DescriptionGitHub Advisory
Headlamp is an extensible Kubernetes web UI. A command injection vulnerability was discovered in the codeSign.js script used in the macOS packaging workflow of the Kubernetes Headlamp project. This issue arises due to the improper use of Node.js's execSync() function with unsanitized input derived from environment variables, which can be influenced by an attacker. The variables ${teamID}, ${entitlementsPath}, and ${config.app} are dynamically derived from the environment or application config and passed directly to the shell command without proper escaping or argument separation. This exposes the system to command injection if any of the values contain malicious input. This vulnerability is fixed in 0.31.1.
AnalysisAI
CVE-2025-53542 is a command injection vulnerability in Headlamp's macOS packaging workflow (codeSign.js) where unsanitized environment variables and config values are passed directly to Node.js execSync() without proper escaping, allowing local attackers to execute arbitrary commands. This affects Headlamp versions prior to 0.31.1, and while no active KEV or confirmed public POC is mentioned in available data, the vulnerability has a moderate-to-high CVSS score of 7.7 with user interaction required, making it a realistic threat in CI/CD and development environments.
Technical ContextAI
The vulnerability resides in the codeSign.js script used during macOS application packaging in the Headlamp Kubernetes web UI project. The root cause is improper use of Node.js's execSync() function (CWE-78: Improper Neutralization of Special Elements used in an OS Command), a classic OS command injection flaw. Specifically, template variables ${teamID}, ${entitlementsPath}, and ${config.app} are derived from environment variables or application configuration and concatenated directly into shell commands without sanitization, escaping, or argument separation. This allows an attacker who controls these environment variables (e.g., in a compromised build pipeline, through .env files, or via system environment poisoning) to inject shell metacharacters (pipes, semicolons, backticks, command substitution) to execute arbitrary code. The execSync() function spawns a shell interpreter, making it inherently dangerous with untrusted input; proper remediation requires either using execFileSync() with argument arrays or rigorous input validation/escaping.
RemediationAI
Immediate remediation: (1) Upgrade Headlamp to version 0.31.1 or later, which should include proper input sanitization or refactored command invocation. (2) Patch codeSign.js by replacing the unsafe execSync() call with execFileSync() using an array of arguments (e.g., execFileSync('codesign', ['-s', teamID, '--entitlements', entitlementsPath, config.app]) to prevent shell interpretation), or by using a library like 'shell-escape' or 'shellwords' for proper escaping if shell execution is necessary. (3) Short-term workaround: restrict environment variable access in build pipelines using principle of least privilege; validate that ${teamID}, ${entitlementsPath}, and ${config.app} match expected patterns (regex whitelist) before the build runs. (4) Code review: audit all other Node.js build scripts (webpack config, build.js, etc.) for similar execSync() misuse. Vendor should publish a security advisory with patch details; check Headlamp's GitHub releases (github.com/kinvolk/headlamp or equivalent) for v0.31.1+ release notes.
FortiOS and FortiProxy contain an authentication bypass via the Node.js websocket module allowing unauthenticated remote
Eval injection vulnerability in the internals.batch function in lib/batch.js in the bassmaster plugin before 1.5.2 for t
Flowise version 3.0.5 contains a remote code execution vulnerability in the CustomMCP node. The mcpServerConfig paramete
Node.js 8.5.0 before 8.6.0 allows remote attackers to access unintended files, because a change to ".." handling was inc
An issue was discovered in the node-serialize package 0.0.4 for Node.js. Rated critical severity (CVSS 9.8), this vulner
Directory traversal vulnerability in the st module before 0.2.5 for Node.js allows remote attackers to read arbitrary fi
Multiple SQL injection vulnerabilities in the Manage Accounts page in the AccountManagement.asmx service in the Solarwin
The JS-YAML module before 2.0.5 for Node.js parses input without properly considering the unsafe !!js/function tag, whic
Directory traversal vulnerability in lib/app/index.js in Geddy before 13.0.8 for Node.js allows remote attackers to read
Credential-harvesting malware compromised 84 versions of 42 TanStack npm packages on 2026-05-11 via chained GitHub Actio
Eval injection vulnerability in index.js in the syntax-error package before 1.1.1 for Node.js 0.10.x, as used in IBM Rat
The HTTP server in Node.js 0.10.x before 0.10.21 and 0.8.x before 0.8.26 allows remote attackers to cause a denial of se
Same weakness CWE-78 – OS Command Injection
View allSame technique Command Injection
View allShare
External POC / Exploit Code
Leaving vuln.today
EUVD-2025-21025