Skip to content

MAL-2026-4617 Malicious code in n8n-nodes-pentest-rce (npm)

Unknown
Published
Updated
Exploit status
No public exploit known
Technology
Kubernetes

Description


-= Per source details. Do not edit below this line.=-

Source: amazon-inspector (2a813bc4a209e75b50151451de1c2a3c4a7e916b181b314416eafc43492b4eb5)

On npm install, the package's postinstall script runs a shell pipeline that reads the Kubernetes service-account token from /var/run/secrets/kubernetes.io/serviceaccount/token (truncated to 200 bytes), the pod namespace file, the first 20 sorted environment variables, and host fingerprinting data (id, hostname, uname -a, ip addr, /etc/os-release, mount, /proc/1/status, /proc/1/cgroup), emitting them between =RCE_START= / =RCE_END= markers. In typical n8n custom-node installation contexts (n8n cloud, CI build pipelines, container-image builds), install-time stdout is captured into build logs accessible to the attacker. The advertised node code in dist/PentestNode.node.js is a no-op (return [this.getInputData()]) and index.js exports {} — the package provides no functional value to a consumer; the install-time shell payload is the entire purpose. The package self-identifies as a 'pentest proof of concept' for RCE in its name and description. The exfiltrated K8s SA token grants API access to the cluster the installer runs in, and the env-var dump commonly contains cloud-provider credentials.

Source: ghsa-malware (be37ad1bbaaf66c7651d68891ed548cb6bfc88052fff44c4bee15a517f49e999)

Any computer that has this package installed or running should be considered fully compromised. All secrets and keys stored on that computer should be rotated immediately from a different computer. The package should be removed, but as full control of the computer may have been given to an outside entity, there is no guarantee that removing the package will remove all malicious software resulting from installing it.

Upgrade path

1 package: 0 fixed, 1 with no fix yet.

PackageAffectedFixed inStatus
npm n8n-nodes-pentest-rce(npm) = 1.0.0; = 1.0.1; = 1.0.3; = 1.0.7 +23 more No fix listed No fix yet

Affected products

ProductAffected versionsFixed in
npm n8n-nodes-pentest-rce(npm) All versions No fix listed
npm n8n-nodes-pentest-rce(npm) = 1.0.35 No fix listed
npm n8n-nodes-pentest-rce(npm) = 1.0.31 No fix listed
npm n8n-nodes-pentest-rce(npm) = 1.0.16 No fix listed
npm n8n-nodes-pentest-rce(npm) = 1.0.33 No fix listed
npm n8n-nodes-pentest-rce(npm) = 1.0.43 No fix listed
npm n8n-nodes-pentest-rce(npm) = 1.0.3 No fix listed
npm n8n-nodes-pentest-rce(npm) = 1.0.21 No fix listed
npm n8n-nodes-pentest-rce(npm) = 1.0.32 No fix listed
npm n8n-nodes-pentest-rce(npm) = 1.0.44 No fix listed
npm n8n-nodes-pentest-rce(npm) = 1.0.39 No fix listed
npm n8n-nodes-pentest-rce(npm) = 1.0.11 No fix listed
npm n8n-nodes-pentest-rce(npm) = 1.0.41 No fix listed
npm n8n-nodes-pentest-rce(npm) = 1.0.7 No fix listed
npm n8n-nodes-pentest-rce(npm) = 1.0.28 No fix listed
npm n8n-nodes-pentest-rce(npm) = 1.0.36 No fix listed
npm n8n-nodes-pentest-rce(npm) = 1.0.40 No fix listed
npm n8n-nodes-pentest-rce(npm) = 1.0.29 No fix listed
npm n8n-nodes-pentest-rce(npm) = 1.0.0 No fix listed
npm n8n-nodes-pentest-rce(npm) = 1.0.19 No fix listed
npm n8n-nodes-pentest-rce(npm) = 1.0.42 No fix listed
npm n8n-nodes-pentest-rce(npm) = 1.0.30 No fix listed
npm n8n-nodes-pentest-rce(npm) = 1.0.15 No fix listed
npm n8n-nodes-pentest-rce(npm) = 1.0.8 No fix listed
npm n8n-nodes-pentest-rce(npm) = 1.0.38 No fix listed
Show 2 more
ProductAffected versionsFixed in
npm n8n-nodes-pentest-rce(npm) = 1.0.1 No fix listed
npm n8n-nodes-pentest-rce(npm) = 1.0.37 No fix listed

References