Fix GHSA-pjwx-r37v-7724 / CVE-2026-44843: bump langchain-core constraint to >=1.3.3 - #272
Conversation
…int to >=1.3.3 Fixes unsafe deserialization of attacker-controlled objects through overly broad load() allowlists in RunnableWithMessageHistory, astream_log(), and astream_events(v1). The previously-locked langchain-core 1.2.28 fell inside the vulnerable >=1.0.0,<=1.3.2 range; 1.3.3 is the first patched 1.x release. Resolver picked langchain-core 1.6.2. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
|
dbezic (@dbezic) Rick Brighenti (@rbrighenti) Krishnadheeraj (@DheerajPannala) could one of you review/approve? (submitted from a fork so I can't formally request review — flagging directly instead, same as #269/#285.) Note: if this repo's integration/secret-dependent CI checks fail on a fork PR, that's the known fork-secrets limitation (pull_request workflows from forks don't get repo secrets), not a problem from this dependency bump — the unit suite (tox -e py312, 800 passed) already covers it locally. |
There was a problem hiding this comment.
🟢 Approval recommended
The change is a targeted constraint bump with clear security justification and no additional code-path modifications introduced in the PR diff.
Pull request overview
Updates the centralized uv dependency constraints to remediate GHSA-pjwx-r37v-7724 / CVE-2026-44843 by requiring a patched langchain-core version in the root workspace constraints.
Changes:
- Bumped the root
constraint-dependenciesentry forlangchain-corefrom>= 0.1.0to>= 1.3.3. - Added inline rationale/comments documenting the CVE impact range and why the constraint remains unbounded.
File summaries
| File | Description |
|---|---|
| pyproject.toml | Raises the centralized langchain-core minimum version to a patched release and documents the security rationale. |
Review details
- Files reviewed: 1/2 changed files
- Comments generated: 0
- Review effort level: Lite
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Summary
Fixes a known vulnerability in the langchain-core dependency by bumping the centralized constraint in root pyproject.toml's [tool.uv] constraint-dependencies from >=0.1.0 to >=1.3.3 (no upper bound, matching the other unbounded AI-framework constraints in the same block).
CVE fixed
GHSA-pjwx-r37v-7724 / CVE-2026-44843 - LangChain unsafe deserialization of attacker-controlled objects through overly broad
load()allowlists (affectsRunnableWithMessageHistory,astream_log(),astream_events(v1), and related serialization/deserialization round-trips). The previously-lockedlangchain-core 1.2.28fell inside the vulnerable>=1.0.0,<=1.3.2range.1.3.3is the first patched 1.x release; the resolver picked up1.6.2.Local verification (this branch)
uv lock: resolves clean (langchain-core 1.2.28 -> 1.6.2)uv sync --locked --all-extras --dev: cleantox -e verify-constraints: PASS (this repo enforces centralized version constraints only in root pyproject.toml)tox -e lint: PASStox -e format: PASStox -e py312: 800 passed, 3 skipped, 9 deselected, 0 failed (full suite, including the langchain observability extension's own 10 tests, all passing against the new version)Reviewers
Requested review from dbezic, rbrighenti, DheerajPannala (same reviewers as the sibling google-adk security fix, #269).
This PR description was drafted with AI assistance. Please review carefully before merging.