---
title: "GHSA-6vc5-vf29-ffr2: @nx/docker: OS command injection in the @nx/docker release pipeline"
description: "High severity. @nx/docker: OS command injection in the @nx/docker release pipeline. Affects @nx/docker; fixed in 23.1.1."
url: https://inlinr.com/advisories/GHSA-6vc5-vf29-ffr2
lang: en
---

[Packages](https://inlinr.com/packages) / [@nx/docker](https://inlinr.com/packages/@nx/docker) / [Security](https://inlinr.com/packages/@nx/docker/security)

High Vulnerability GHSA-6vc5-vf29-ffr2 CVE-2026-104859 Published 5 Oct 2026

# @nx/docker: OS command injection in the @nx/docker release pipeline

Your version 

Affected releases · [@nx/docker](https://inlinr.com/packages/@nx/docker)

- 23.x 23.0.0 – 23.1.0 Fixed in 23.1.1
- 22.x 22.0.0 – 22.7.7 Fixed in 22.7.8
- 21.x 21.4.0 – 21.6.11 No fix on this line yet

On 23.x, the newest line:

```
npm install @nx/docker@23.1.1
```

Every release on a timeline

24.x 

1. Not affected

24.0.0 – 24.0.6  
7 releases, latest

23.x 

1. Affected

23.0.0 – 23.1.0  
4 releases
2. Fixed

23.1.1 – 23.3.3  
9 releases

22.x 

1. Affected

22.0.0 – 22.7.7  
46 releases
2. Fixed

22.7.8 – 22.7.12  
5 releases

21.x 

1. Affected

21.4.0 – 21.6.11  
16 releases

87 stable releases of @nx/docker, oldest to newest, one row per major.

## What happens

Summary

The [@nx/docker](https://inlinr.com/packages/@nx/docker) release pipeline builds its `docker` invocations as shell command strings, interpolating `release.docker.repositoryName` and `registryUrl` from Nx configuration into them. Because those strings are handed to `/bin/sh -c`, a crafted repository or registry name executes as a command during `nx release version` and `nx release publish`. Anyone running a Docker release against a repository whose Nx configuration they do not control — or whose configuration a pull request has changed — executes the injected command with the privileges of the release job, which in CI typically holds registry credentials and cloud tokens.

Severity

Exploitable when someone runs a Docker release against attacker-supplied configuration, with high impact because release jobs hold publishing credentials. There is no known evidence of exploitation in the wild.

Affected & Patched Versions

| Package                                              | Vulnerable                                 | Patched        |
| ---------------------------------------------------- | ------------------------------------------ | -------------- |
| [@nx/docker](https://inlinr.com/packages/@nx/docker) | \>= 21.4.0, < 22.7.8; \>= 23.0.0, < 23.1.1 | 22.7.8, 23.1.1 |

Every published [@nx/docker](https://inlinr.com/packages/@nx/docker) release before the patched versions is affected.

Important

`--dry-run` does not protect you: one of the injected commands runs before the dry-run check, so even a dry-run publish reaches a shell.

Remediation

Upgrade to **22.7.8** (22.x line) or **23.1.1** (23.x line) or later:

```
nx migrate 23.1.1
```

The fix is a drop-in and requires no configuration change. If you have run `nx release version` with a configuration you do not trust, delete the generated Docker version file before your next publish, since the composed reference is read back from disk.

Details

Several `docker` commands in the release pipeline (`docker tag` during `nx release version`; the image existence check and `docker push` during `nx release publish`) are built as shell command strings with the image reference interpolated in. The reference is composed from the project's `release.docker` `repositoryName` and `registryUrl`, so a value containing shell syntax is executed rather than passed to `docker`.

Credits

- **Arkadiusz Marta** (RE:SOURCE) — Reporter

## How it is exploited

Exploitable with local access, with no account and a user to do something.

- **Confidentiality**: high
- **Integrity**: high
- **Availability**: high

CVSS:4.0/​AV:L/​AC:L/​AT:P/​PR:N/​UI:P/​VC:H/​VI:H/​VA:H/​SC:N/​SI:N/​SA:N

## References

- [Reference](https://github.com/nrwl/nx/security/advisories/GHSA-6vc5-vf29-ffr2 "https://github.com/nrwl/nx/security/advisories/GHSA-6vc5-vf29-ffr2")  
github.com/nrwl/nx/security/advisories/GHSA-6vc…
- [NVD](https://nvd.nist.gov/vuln/detail/CVE-2026-104859 "https://nvd.nist.gov/vuln/detail/CVE-2026-104859")  
nvd.nist.gov/vuln/detail/CVE-2026-104859
- [Pull request](https://github.com/nrwl/nx/pull/36505 "https://github.com/nrwl/nx/pull/36505")  
#36505
- [Fix commit](https://github.com/nrwl/nx/commit/6d60eed061f050e0d5af509a1f5a07c707f09865 "https://github.com/nrwl/nx/commit/6d60eed061f050e0d5af509a1f5a07c707f09865")  
6d60eed
- [Fix commit](https://github.com/nrwl/nx/commit/b587441fd8da28c5db37edb0826554e0060dc81b "https://github.com/nrwl/nx/commit/b587441fd8da28c5db37edb0826554e0060dc81b")  
b587441
- [Package](https://github.com/nrwl/nx "https://github.com/nrwl/nx")  
github.com/nrwl/nx

A whole project to check? Paste its package.json in the [dependency check](https://inlinr.com/tools/dependency-check): every deprecated, outdated or vulnerable dependency, with what to upgrade to. Free, no account.
