UNC6426 Exploits nx npm Supply-Chain Attack for AWS Admin Access
- [01] Threat actor UNC6426 used stolen GitHub tokens to gain full AWS administrative access and exfiltrate sensitive cloud data within 72 hours.
- [02] Organizations using the compromised nx npm package versions are at risk of complete cloud environment takeover via stolen developer credentials.
- [03] Revoke all GitHub personal access tokens and AWS IAM keys associated with developers who interacted with the compromised nx package versions.
A sophisticated threat actor, tracked as UNC6426, has successfully parlayed a Supply Chain Attack into full cloud environment domination. By leveraging credentials stolen during the historical compromise of the nx npm package, the group demonstrated an alarming speed of execution, reaching administrative control over a victim’s Amazon Web Services (AWS) environment in just three days. This incident highlights the persistent risk of developer-targeted credential theft and the downstream impact of compromised build tools.
Technical Analysis: From GitHub Token to AWS Admin
The breach began not with a direct exploit of a web-facing service, but through the exploitation of long-lived secrets harvested during the nx package compromise. according to The Hacker News, the attackers initially gained access to a developer’s GitHub token. This token served as the primary entry point, allowing the actor to bypass traditional perimeter defenses and interact directly with the victim’s private code repositories.
Once inside the GitHub environment, UNC6426 performed extensive reconnaissance to identify further secrets stored in code or CI/CD pipelines. This led to the discovery of AWS Identity and Access Management (IAM) keys. This sequence illustrates a rapid escalation from a localized developer compromise to a wide-scale UNC6426 cloud environment breach. Within the 72-hour window, the actor utilized these keys to perform Lateral Movement within the cloud infrastructure, eventually gaining administrative privileges that permitted data exfiltration and complete environment visibility.
How to Detect nx npm Supply Chain Attack Indicators
Detecting this specific threat requires a multi-layered approach focusing on identity telemetry and repository audit logs. Organizations should prioritize searching for IoC patterns such as unusual IP addresses accessing GitHub personal access tokens (PATs), especially those originating from known VPN or VPS exit nodes.
Defenders must also monitor for the following activities:
- Unexpected cloning of multiple private repositories by a single developer token.
- Creation of new AWS IAM users or the attachment of administrative policies to existing low-privileged accounts.
- API calls to AWS STS (Security Token Service) originating from non-corporate environments or suspicious geolocations.
In many cases, detecting unauthorized AWS administrative access relies on identifying the misuse of legitimate credentials rather than the presence of C2 malware. Security teams should integrate their GitHub audit logs into their SIEM to correlate repository access with subsequent cloud infrastructure changes.
Mitigation and Strategic Recommendations
The speed at which UNC6426 moved highlights the inadequacy of static credentials in modern development workflows. To mitigate the risk of similar Supply Chain Attack scenarios, the SOC should lead a transition toward short-lived, identity-based access.
- Enforce Token Expiration: All GitHub PATs should have mandatory expiration dates and be limited to the minimum necessary scopes.
- Rotate Credentials: If your organization used the
nxpackage during the period of its compromise, treat all secrets handled by developers during that time as compromised and rotate them immediately. - Implement OIDC for CI/CD: Move away from long-lived AWS IAM keys in GitHub Actions. Use OpenID Connect (OIDC) to allow GitHub to request temporary credentials from AWS, eliminating the need to store secrets in the repository settings.
- Hardware-Based MFA: Enforce FIDO2-compliant multi-factor authentication for all developer accounts to prevent token theft via Phishing or session hijacking.
While the immediate threat of the nx package compromise has been addressed by the maintainers, the lifecycle of the stolen data remains a long-term risk. Continuous monitoring for anomalous developer behavior is essential to identify actors who may be sitting on stolen tokens for future exploitation.
Advertisement