Malicious code in publish-poc-base (npm)
--- _-= Per source details. Do not edit below this line.=-_ ## Source: amazon-inspector (9bf2f71038e46898cc03f9bf5081547bb6d725e6a480ef22b80f4dc259c721d9) On install, the postinstall script in package.json reads the first line of../../README.md from the installer's parent workspace, creates a mktemp directory, writes a generated package.json named publish-poc-found- using that README content as its description, and writes an.npmrc containing a hardcoded npm registry _authToken (prefix npm_DLcrGeNT…) pointing at //registry.npmjs.org/. The staged directory is removed with rm -rf before any publish or network call fires, so this version does not itself execute the publish step, but the shipped token is distributed in cleartext to every installer and the staging logic is a working template for auto-publishing packages under the token owner's identity using data harvested from the installer's workspace. The combination of a live third-party-usable publish credential distributed to all installers plus install-time reads of files outside the package directory raises installer-impacting supply-chain concerns beyond author self-harm: any installer receives the token, and any installer's local README content is read at install time.
- Products
- publish-poc-base
- Affected versions
- 1.0.7
- Fixed versions
- Not specified
- CVEs
- Not specified
- Confirmed fixed CVEs
- Not specified
- Updated in this feed
- 1 Nov 2026, 10:35 UTC · Revision 1
Source evidence
--- _-= Per source details. Do not edit below this line.=-_ ## Source: amazon-inspector (9bf2f71038e46898cc03f9bf5081547bb6d725e6a480ef22b80f4dc259c721d9) On install, the postinstall script in package.json reads the first line of../../README.md from the installer's parent workspace, creates a mktemp directory, writes a generated package.json named publish-poc-found- using that README content as its description, and writes an.npmrc containing a hardcoded npm registry _authToken (prefix npm_DLcrGeNT…) pointing at //registry.npmjs.org/. The staged directory is removed with rm -rf before any publish or network call fires, so this version does not itself execute the publish step, but the shipped token is distributed in cleartext to every installer and the staging logic is a working template for auto-publishing packages under the token owner's identity using data harvested from the installer's workspace. The combination of a live third-party-usable publish credential distributed to all installers plus install-time reads of files outside the package directory raises installer-impacting supply-chain concerns beyond author self-harm: any installer receives the token, and any installer's local README content is read at install time.
osv:MAL-2026-18323
publish-poc-base
Fixed versions: Not specified
Complete source record
{
"id": "9f1f286f905525d27094e0cc8cffd8b29d3834b13788ee00ce3837deef2180c4",
"url": "https://osv.dev/vulnerability/MAL-2026-18323",
"method": "structured",
"payload": {
"kind": "advisory",
"title": "Malicious code in publish-poc-base (npm)",
"summary": "--- _-= Per source details. Do not edit below this line.=-_ ## Source: amazon-inspector (9bf2f71038e46898cc03f9bf5081547bb6d725e6a480ef22b80f4dc259c721d9) On install, the postinstall script in package.json reads the first line of../../README.md from the installer's parent workspace, creates a mktemp directory, writes a generated package.json named publish-poc-found- using that README content as its description, and writes an.npmrc containing a hardcoded npm registry _authToken (prefix npm_DLcrGeNT…) pointing at //registry.npmjs.org/. The staged directory is removed with rm -rf before any publish or network call fires, so this version does not itself execute the publish step, but the shipped token is distributed in cleartext to every installer and the staging logic is a working template for auto-publishing packages under the token owner's identity using data harvested from the installer's workspace. The combination of a live third-party-usable publish credential distributed to all installers plus install-time reads of files outside the package directory raises installer-impacting supply-chain concerns beyond author self-harm: any installer receives the token, and any installer's local README content is read at install time.",
"evidence": "osv:MAL-2026-18323",
"products": [
{
"name": {
"value": "publish-poc-base",
"evidence": "/affected/0/package/name"
},
"prerequisites": [],
"fixed_versions": [],
"affected_versions": [
{
"value": "1.0.7",
"evidence": "/affected/0/versions"
}
]
}
],
"severity": "unknown",
"structured": {
"id": "MAL-2026-18323",
"aliases": [
"MAL-2026-18323"
],
"affected": [
{
"package": {
"name": "publish-poc-base",
"purl": "pkg:npm/publish-poc-base",
"ecosystem": "npm"
},
"versions": [
"1.0.7"
],
"database_specific": {
"cwes": [
{
"name": "Embedded Malicious Code",
"cweId": "CWE-506",
"description": "The product contains code that appears to be malicious in nature."
}
],
"source": "https://github.com/ossf/malicious-packages/blob/main/osv/malicious/npm/publish-poc-base/MAL-2026-18323.json",
"indicators": {
"evidence_files": [
{
"path": "package.json",
"tlsh": "3be0dc34a600c8234188192c59323c2665255e0f40689a8950a74088a1482f23c4f22a",
"sha256": "7183f5648912fd5ec10805852df799854027312779bcbce5b2ed915b67fc5d43"
}
],
"package_integrity": [
{
"hashes": {
"sha1": "a68159cf95a6e6ed7fafc3dbd593c5c6293d478a",
"sha512_sri": "sha512-S7qNtTAZWYDPIxds9vG75NSftXTC+i9Frb7sStzXxUHm/R/y9ffcH5uRfA8zQm4gRGK+2E2FZ8IQMrun32VDAg=="
},
"filename": "publish-poc-base-1.0.7.tgz"
}
]
}
}
}
],
"modified": "2026-10-26T06:45:16.034881471Z",
"provider": "osv",
"references": [
"https://www.npmjs.com/package/publish-poc-base/v/1.0.7"
],
"provider_metadata": {
"malicious-packages-origins": [
{
"id": "IN-MAL-2026-021775",
"sha256": "9bf2f71038e46898cc03f9bf5081547bb6d725e6a480ef22b80f4dc259c721d9",
"source": "amazon-inspector",
"versions": [
"1.0.7"
],
"import_time": "2026-10-26T06:39:42.057596264Z",
"modified_time": "2026-10-26T06:31:13Z"
}
]
}
},
"related_cves": [],
"security_relevant": true,
"severity_evidence": null
},
"source_id": "core-osv",
"document_id": 446738,
"published_at": "2026-10-26T06:31:13+00:00"
}