bw1.js
Hunt this family in your stack
Mallory pivots from this family to the IOCs, detections, and named campaigns that touch your stack, and pages you when something new lands.
Techniques & procedures
30 distinct techniques documented for this family, organized by ATT&CK tactic.
Initial Access
3 techniques
Initial Access
First, it validates stolen GitHub tokens against https://api.github.com/user .
JFrog security researchers identified a hijacked npm package published as @bitwarden/cli version 2026.4.0, impersonating the legitimate Bitwarden command line client.
When a valid npm token with bypass_2fa and package:write permissions is found, the malware pivots to active supply chain propagation... injects preinstall: node setup.mjs into package.json... Republishes to npm with the stolen auth token. | Bitwarden’s command-line interface (CLI) has been compromised in a software supply chain attack. The malicious version 2026.4.0 of the npm package @bitwarden/cli was available on npm...
Execution
4 techniques
Execution
the payload used them to inject malicious workflows into victim repositories, giving the attacker a durable foothold and an automated path to spreading further.
The shell collector explicitly runs gh auth token and also captures process.env
The malicious package.json declares version 2026.4.0 with legitimate-looking Bitwarden metadata. The attack vector is a single field: { "name": "@bitwarden/cli", "version": "2026.4.0", "scripts": { "preinstall": "node bw_setup.js" } } ... preinstall runs before npm finishes installing the package. The developer does not need to run the tool or import it. Installing is enough.
Persistence
5 techniques
Persistence
the payload used them to inject malicious workflows into victim repositories, giving the attacker a durable foothold and an automated path to spreading further.
First, it validates stolen GitHub tokens against https://api.github.com/user .
With a working PAT, it creates a repository in the victim account and uploads encrypted JSON blobs under a results/ directory.
Privilege Escalation
3 techniques
Privilege Escalation
Stealth
4 techniques
Stealth
bw1.js is 9.7 MB of heavily obfuscated JavaScript processed through obfuscator.io. It contains a 43,436-entry string lookup table using a custom base64 alphabet, a seeded pseudo-random scramble table for the most sensitive strings (C2 domain, file paths), and six gzip-compressed payload blobs referenced by index.
First, it validates stolen GitHub tokens against https://api.github.com/user .
Defense Impairment
1 technique
Defense Impairment
Credential Access
8 techniques
Credential Access
looks for AWS credentials in ~/.aws/credentials... targets GCP credential storage in ~/.config/gcloud/credentials.db ... AWS, GCP, and Azure secrets
mcpAddon.js is designed to sweep development environments for high-value secrets, including GitHub tokens, npm tokens, AWS/Azure/GCP credentials, SSH keys, environment variables, and configuration files for Claude and other AI tools.
All extend a common $f base class with pattern-matching for ghp_*, gho_* (GitHub tokens), and npm_* (npm tokens)... Filesystem scanner... plausible targets include ~/.ssh/id_rsa, ~/.npmrc, ~/.aws/credentials...
The malicious payload collects CI secrets such as SSH keys or API tokens... plausible targets include ~/.ssh/id_rsa...
MITRE attack mapping ... Credential Access T1552.001 / .004 / .007 Files, private keys, container/cloud API
The filesystem sweep went after... SSH private keys, .git-credentials, .npmrc, .env files... AWS credential and config files... GCP credentials... Azure credentials... and a comprehensive pile of token files. | The shell collector explicitly ran gh auth token to grab the user's GitHub CLI token, then scanned process.env for anything matching ghp_[A-Za-z0-9]{36} ... or npm_[A-Za-z0-9]{36,} ...
stolen GitHub tokens were weaponized in-line: the payload used them to inject malicious workflows into victim repositories, giving the attacker a durable foothold and an automated path to spreading further.
It steals credentials from cloud providers, AI tool configurations, SSH keys, and git credentials... Linux targets: ~/.ssh/id_* SSH private keys ... ~/.aws/credentials AWS access keys ... ~/.config/gcloud/credentials.db Google Cloud credentials ... .git-credentials Git credentials
Discovery
5 techniques
Discovery
The payload runs three primary collectors: A filesystem collector A shell and environment collector A GitHub Actions runner collector
Filesystem scanner, Walks OS-specific 'hotspot' paths... reading files up to 5 MB each... Windows targets are plaintext in the binary: ['.env', 'config.ini'].
Before performing any malicious activity, bw1.js runs a gauntlet of self-termination checks... System locale starts with ru... process.exit(0)... Not running in any CI/CD environment and daemonization fails... process.exit(0).
Collection
3 techniques
Collection
Seven independent collectors run in parallel and feed a shared result store... Filesystem scanner... Shell and environment scanner... dumps the entire process.env object.
Command and Control
2 techniques
Command and Control
Exfiltration
2 techniques
Exfiltration
The primary exfil channel was audit.checkmarx[.]cx/v1/telemetry, a domain that typosquats the real checkmarx.com and was designed to look like legitimate telemetry from a security tool. | If the primary endpoint is unreachable, the payload uses a stolen GitHub PAT to create a new public repository on the victim’s GitHub account... Encrypted results get committed as results/results-<timestamp>-<counter>.json batches...
IOCs tracked for this family
2 indicators attributed across vendor reports, sandbox runs, and researcher write-ups. Full values are available in Mallory.
IPs, domains, and DNS infrastructure linked to this family.
Recent activity
1 sources tracked across advisories, community write-ups, and news. New activity surfaces here as Mallory finds it.
The version that knows your environment.
Match every observed IP, domain, and hash against your live telemetry.
Named campaigns wielding this family, with evidence pinned to each claim.
CVEs this family uses for access and lateral movement.
YARA, Sigma, Snort, and vendor rules, auto-deployed to your SIEM.
Every documented technique, ranked by evidence weight.
Reddit, Mastodon, and CTI community discussion around this family.