Skip to content

build: bump starlette to 1.3.1 and tornado to 6.5.6 to fix container CVEs#4396

Closed
ko3n1g wants to merge 2 commits into
mainfrom
ko3n1g/build/bump-starlette-cve
Closed

build: bump starlette to 1.3.1 and tornado to 6.5.6 to fix container CVEs#4396
ko3n1g wants to merge 2 commits into
mainfrom
ko3n1g/build/bump-starlette-cve

Conversation

@ko3n1g

@ko3n1g ko3n1g commented Jun 16, 2026

Copy link
Copy Markdown
Contributor

Background / motivation

The 26.06.rc8 NeMo FW container scan flagged three High-severity CVEs across two Python installs in the image:

CVE Package Summary Patched
GHSA-82w8-qh3p-5jfq starlette request.form() size limits silently ignored → DoS 1.3.1
GHSA-wqp7-x3pw-xc5r starlette StaticFiles UNC-path SSRF / NTLM theft (Windows-only) 1.1.0
GHSA-mgf9-4vpg-hj56 tornado AsyncHTTPClient accumulates decompressed chunks without limit (gzip bomb) → DoS 6.5.6

Both starlette CVEs are patched only in the 1.x line (no 0.x backport).

The scan's Package Location column splits these across the two installs the image carries, and both are owned by this repo's Docker build:

  • /opt/venv/.../site-packages — the uv-managed install (uv.lock): starlette 0.52.1.
  • /usr/local/lib/python3.12/dist-packages — the system interpreter, pinned in docker/Dockerfile.fw_final's "Address CVE" block: starlette 0.49.1, tornado 6.5.5.

What changed

uv-managed (/opt/venv):

  • Pin starlette>=1.3.1 via [tool.uv] override-dependencies (transitive — pulled by fastapi, mlflow-skinny, prometheus-fastapi-instrumentator, sphinx-autobuild).
  • Bump prometheus-fastapi-instrumentator 7.0.0 → 8.0.0 (its 7.x line caps starlette<1.0.0; 8.x requires >=1.0.0).
  • Regenerated uv.lock: starlette 0.52.1 → 1.3.1, prometheus-fastapi-instrumentator 7.0.0 → 8.0.0. No other packages change.

system interpreter (/usr/local/lib/.../dist-packages), docker/Dockerfile.fw_final:

  • starlette==0.49.1 → 1.3.1
  • tornado==6.5.5 → 6.5.6

Details

  • The uv-side CVE floor follows the repo's existing override-dependencies pattern (urllib3>=2.6.3, langchain>=0.3.28, …).
  • fastapi (>=0.46.0), mlflow-skinny (<2) and sphinx-autobuild (>=0.35) already permit starlette 1.x; only prometheus-fastapi-instrumentator had to move with it.
  • The fw_final bumps stay in the block's existing exact-pin style. tornado is an explicit pin there (not just a wandb[launch] transitive), so it has to be bumped directly.

Tested

  • uv lock --upgrade-package starlette --upgrade-package prometheus-fastapi-instrumentator (run in container) resolved 349 packages cleanly, no rebuilds:
    • Updated starlette v0.52.1 -> v1.3.1
    • Updated prometheus-fastapi-instrumentator v7.0.0 -> v8.0.0
  • starlette==1.3.1 and tornado==6.5.6 confirmed present on PyPI.
  • pre-commit clean on changed files.
  • CI to validate the full image build + test matrix (this crosses the starlette 0.x→1.x major boundary, so the build/functional jobs are the real check that fastapi/vllm/instrumentator paths still import cleanly).

…p7-x3pw-xc5r

Remediate two High-severity starlette CVEs in the uv-managed /opt/venv install:

- GHSA-82w8-qh3p-5jfq (request.form() limit bypass DoS), patched in 1.3.1
- GHSA-wqp7-x3pw-xc5r (StaticFiles UNC SSRF, Windows-only), patched in 1.1.0

starlette is transitive (fastapi, mlflow-skinny, prometheus-fastapi-instrumentator,
sphinx-autobuild); neither CVE has a 0.x backport, so the floor is pinned via
[tool.uv] override-dependencies, matching the existing CVE-remediation pattern.

prometheus-fastapi-instrumentator is bumped 7.0.0 -> 8.0.0 because its 7.x line
caps starlette<1.0.0; the 8.x line requires starlette>=1.0.0. fastapi,
mlflow-skinny and sphinx-autobuild already permit starlette 1.x.

Does not address the system-level (/usr/local/lib dist-packages) starlette/tornado
findings, which live in the fw_final image, not this uv-managed environment.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Signed-off-by: oliver könig <okoenig@nvidia.com>
@copy-pr-bot

copy-pr-bot Bot commented Jun 16, 2026

Copy link
Copy Markdown

Auto-sync is disabled for draft pull requests in this repository. Workflows must be run manually.

Contributors can view more details about this message here.

@ko3n1g ko3n1g added area:build Dependencies, packaging, images, and environment setup bug Something isn't working labels Jun 16, 2026
…fw_final

The fw_final 'Address CVE' block pins packages in the system interpreter
(/usr/local/lib/python3.12/dist-packages). Two of those pins are now flagged
by the same scan:

- starlette==0.49.1 -> 1.3.1 (GHSA-82w8-qh3p-5jfq, GHSA-wqp7-x3pw-xc5r)
- tornado==6.5.5 -> 6.5.6 (GHSA-mgf9-4vpg-hj56, AsyncHTTPClient gzip-bomb DoS)

This is the system-level counterpart to the uv-managed /opt/venv starlette bump
in the previous commit; both installs are flagged separately by the scanner.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Signed-off-by: oliver könig <okoenig@nvidia.com>
@ko3n1g ko3n1g changed the title build: bump starlette to 1.3.1 to fix GHSA-82w8-qh3p-5jfq and GHSA-wqp7-x3pw-xc5r build: bump starlette to 1.3.1 and tornado to 6.5.6 to fix container CVEs Jun 16, 2026
@ko3n1g

ko3n1g commented Jun 16, 2026

Copy link
Copy Markdown
Contributor Author

/ok to test

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:build Dependencies, packaging, images, and environment setup bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant