Executive brief
The @nx/azure-cache plugin for the Nx build system is vulnerable to cache poisoning attacks that allow contributors with pull request privileges to inject compromised build artifacts into shared caches used by trusted environments and production deployments. An attacker can exploit this vulnerability to inject malicious artifacts that will be used by downstream builds without detection, potentially leading to supply chain compromise and deployment of malicious code to production. This bypasses traditional security measures including encryption and access controls by poisoning the cache during the artifact construction phase.
Technical details
This vulnerability exploits a fundamental design flaw in the "first-to-cache wins" principle used by bucket-based remote cache systems (Amazon S3, Google Cloud Storage, etc.). Any contributor with pull request privileges can build artifacts in an untrusted environment (feature branch, pull request) and have them cached with the same key as trusted builds, allowing malicious artifacts to poison the cache used by protected branches and production deployments. The attack vector is network-based and requires only pull request privileges with no additional authentication; no user interaction is needed. The root cause is that cache poisoning occurs during artifact construction before security measures like encryption and checksums are applied, making detection impossible. The vulnerability affects all versions of @nx/azure-cache through version 4.0.0, and patches are expected from the maintainers.
Affected products
- Nx (nrwl) @nx/azure-cache 0 through 4.0.0
Timeline
- 2025-06-10: disclosed: Vulnerability published and CVE-2025-36852 assigned
- 2025-10-14: advisory: GitHub security advisory GHSA-rrr2-jcr8-7q3x reviewed and finalized