Skip to content

security: fix remaining Dependabot alerts (94 open) - #7

Merged
as791 merged 2 commits into
mainfrom
fix/dependabot-vulnerabilities
Jul 30, 2026
Merged

security: fix remaining Dependabot alerts (94 open)#7
as791 merged 2 commits into
mainfrom
fix/dependabot-vulnerabilities

Conversation

@as791

@as791 as791 commented Jul 30, 2026

Copy link
Copy Markdown
Owner

Summary

Closes the 94 open Dependabot alerts on main (50 high, 38 moderate, 6 low):

File Package Was Now
MLService/inference/embedder/requirements.txt fastapi 0.121.0 0.135.0
" starlette 0.49.1 1.3.1
" Pillow 12.2.0 12.3.0
" filelock 3.16.1 3.20.3
" torch 2.7.1 2.9.1
MLService/requirements.txt torch / torchvision 2.7.1 / 0.22.1 2.9.1 / 0.24.1
" transformers 4.50.0 5.5.0
" Pillow 12.2.0 12.3.0
" idna (unpinned) 3.15
MLService/extractor/requirements.txt Pillow / idna 12.2.0 / 3.10 12.3.0 / 3.15
tests/requirements.txt Pillow / pytest 12.2.0 / 8.4.2 12.3.0 / 9.0.3
web/package.json next 15.5.19 15.5.21
" postcss ^8.5.10 ^8.5.25 (+ override so next's bundled copy matches)
" sharp 0.34.5 0.35.3 (via override)

fastapi needed a real bump (not just the starlette pin) since every fastapi release capping below 0.51 still requires starlette<0.51, which excludes starlette's whole 1.x line — 0.135.0 is the first release with an open-ended starlette>=0.46.0.

Bonus fix, found while verifying this didn't ship broken: transformers's SiglipModel.get_text_features() / get_image_features() now return the raw BaseModelOutputWithPooling instead of the pooled tensor (a transformers 5.x behavior change, unrelated to this PR's version bumps). Every /embed/text and /embed/image call in embedder/app.py was silently 500ing. Fixed by extracting .pooler_output.

Test plan

  • pip install --dry-run resolves cleanly for all 4 touched requirements.txt files
  • docker compose build embedder extractor chunker normalizer mlservice — all succeed
  • docker compose up — all 4 services stay up, no crash-loop
  • Embedder tested live in a running container: /embed/text and /embed/image both return real 768-d vectors (were 500ing before the app.py fix)
  • web/: npm run build succeeds, npm audit → 0 vulnerabilities
  • Reviewer: re-run Dependabot scan on merge to confirm the alert count drops to 0

🤖 Generated with Claude Code

as791 and others added 2 commits July 31, 2026 01:47
…m, 6 low)

Python (MLService/*, tests/):
- Pillow 12.2.0 -> 12.3.0 (multiple decompression-bomb/OOB-write CVEs)
- torch 2.7.1 -> 2.9.1, torchvision 0.22.1 -> 0.24.1 (matching pair;
  memory corruption + resource-shutdown CVEs)
- transformers 4.50.0 -> 5.5.0 in MLService/requirements.txt (RCE in
  Trainer/LightGlue model loading, multiple ReDoS)
- idna 3.10 -> 3.15 (IDNA encode bypass of prior CVE fix)
- filelock 3.16.1 -> 3.20.3 (TOCTOU symlink race)
- pytest 8.4.2 -> 9.0.3 (vulnerable tmpdir handling)
- starlette 0.49.1 -> 1.3.1 (several CVEs: SSRF/NTLM via UNC paths, DoS,
  arbitrary method dispatch); fastapi bumped 0.121.0 -> 0.135.0 to match
  (needed a version with an open-ended starlette>= requirement, since
  no fastapi release capping below 0.51 supports starlette's 1.x line)

web/:
- next 15.5.19 -> 15.5.21 (SSRF, DoS, cache confusion, disclosure)
- sharp 0.34.5 -> 0.35.3 via override (libvips CVEs)
- postcss 8.5.10 -> 8.5.25, with an overrides entry forcing next's
  bundled nested postcss to the same version - next vendors its own
  copy that a plain devDependency bump doesn't reach
- npm audit: 0 vulnerabilities (was 2, both after the above bump)

Also fixes a real regression this surfaced: transformers>=5's
SiglipModel.get_text_features()/get_image_features() return the raw
BaseModelOutputWithPooling instead of the pooled tensor - every
/embed/text and /embed/image call was 500ing. Extract .pooler_output
explicitly. Verified against a live container: both endpoints return
real 768-d embeddings post-fix.

Verified: pip resolves cleanly for all 4 requirements.txt files, all
affected Docker images (embedder, extractor, chunker, normalizer,
mlservice) build and start without crash-looping, web/ builds clean,
embedder's actual embed endpoints tested end-to-end against a running
container.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
@as791
as791 merged commit 62279ec into main Jul 30, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant