Skip to content

fix(wren-ai-service): upgrade litellm to 1.83.7 (SQL injection CVE) - #2207

Merged
yichieh-lu merged 1 commit into
mainfrom
fix/litellm-cve-1.83.7
May 4, 2026
Merged

yichieh-lu merged 1 commit into
mainfrom
fix/litellm-cve-1.83.7

Conversation

@yichieh-lu

@yichieh-lu yichieh-lu commented May 4, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

  • Bumps litellm from ^1.83.0 to ^1.83.7 to patch the proxy API key verification SQL injection vulnerability (affects >= 1.81.16, < 1.83.7). Resolves to 1.83.14 in lock.
  • Loosens ollama (^0.2.1 → ^0.4.0) and ollama-haystack (^0.0.6 → ^2.0.0) — required because litellm 1.83.7+ pins httpx == 0.28.1 while the old ollama ^0.2.1 capped httpx <0.28. This is what blocked Dependabot's auto-update.
  • Real-world CVE exposure for this service is minimal: wren-ai-service uses litellm purely as an SDK (Router, acompletion, aembedding); no proxy server is started. The vulnerable code path is in litellm's proxy POST /chat/completions flow, which is never executed here. Upgrading still recommended to stay current and clear the alert.

Test plan

  • poetry lock resolves cleanly with no version conflicts
  • poetry install succeeds
  • Smoke import: from litellm import Router, acompletion, aembedding
  • Import src.providers.llm.litellm, src.providers.embedder.litellm, src.config, src.globals — all OK
  • pytest --collect-only tests/pytest --ignore=tests/pytest/eval collects 100 tests with no errors
  • Full just test against Docker pipeline deps (Qdrant + engine) — to be run in CI / by reviewer

🤖 Generated with Claude Code

Summary by CodeRabbit

  • Chores
    • Updated core dependencies to latest compatible versions for improved stability and performance.

…CVE)

CVE affects litellm >= 1.81.16, < 1.83.7 (proxy API key verification path).
Bumping required loosening ollama and ollama-haystack constraints because
litellm 1.83.7+ requires httpx 0.28.1 while the old ollama ^0.2.1 pin
required httpx <0.28, which is what blocked Dependabot's auto-update.

- litellm: ^1.83.0 -> ^1.83.7 (resolves to 1.83.14)
- ollama: ^0.2.1 -> ^0.4.0
- ollama-haystack: ^0.0.6 -> ^2.0.0

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@coderabbitai

coderabbitai Bot commented May 4, 2026 •

Copy link
Copy Markdown
Contributor

Caution

Review failed

Pull request was closed or merged during review

Walkthrough

Dependency version constraints in pyproject.toml are updated: ollama-haystack bumped to ^2.0.0, ollama to ^0.4.0, and litellm to ^1.83.7. No code logic or public API changes.

Changes

Dependency Version Bumps

Layer / File(s) Summary
Runtime Dependencies
wren-ai-service/pyproject.toml
ollama-haystack (^0.0.6 → ^2.0.0), ollama (^0.2.1 → ^0.4.0), and litellm (^1.83.0 → ^1.83.7) version constraints updated.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~8 minutes

Possibly related PRs

Suggested labels

module/ai-service, dependencies, wren-ai-service

Suggested reviewers

  • cyyeh
  • paopa

Poem

🐰 Deps dance higher, versions bright,
Ollama leaps to stellar height,
LiteLLM glows with minor glow,
Each bump takes us where we'll go!

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately describes the main change: upgrading litellm to 1.83.7 for a SQL injection CVE fix, which is the primary objective. It is specific and clearly communicates the purpose of the changeset.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix/litellm-cve-1.83.7

Tip

💬 Introducing Slack Agent: The best way for teams to turn conversations into code.

Slack Agent is built on CodeRabbit's deep understanding of your code, so your team can collaborate across the entire SDLC without losing context.

  • Generate code and open pull requests
  • Plan features and break down work
  • Investigate incidents and troubleshoot customer tickets together
  • Automate recurring tasks and respond to alerts with triggers
  • Summarize progress and report instantly

Built for teams:

  • Shared memory across your entire org—no repeating context
  • Per-thread sandboxes to safely plan and execute work
  • Governance built-in—scoped access, auditability, and budget controls

One agent for your entire SDLC. Right inside Slack.

👉 Get started


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share
Review rate limit: 7/8 reviews remaining, refill in 7 minutes and 30 seconds.

Comment @coderabbitai help to get the list of available commands and usage tips.

@cyyeh
cyyeh self-requested a review May 4, 2026 02:47
@yichieh-lu
yichieh-lu merged commit e42b8d0 into main May 4, 2026
8 of 9 checks passed
@yichieh-lu
yichieh-lu deleted the fix/litellm-cve-1.83.7 branch May 4, 2026 02:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants