Skip to content

Fix critical and high severity Dependabot vulnerabilities#70

Merged
davida-ps merged 1 commit intomainfrom
claude/explain-codebase-mlnit1low1h8d0o2-uetH4
Feb 15, 2026
Merged

Fix critical and high severity Dependabot vulnerabilities#70
davida-ps merged 1 commit intomainfrom
claude/explain-codebase-mlnit1low1h8d0o2-uetH4

Conversation

@davida-ps
Copy link
Collaborator

@davida-ps davida-ps commented Feb 15, 2026

User description

Upgrade langchain ecosystem to 0.3.x to fix CVE-2025-68664 (CVSS 9.3 Critical - serialization injection allowing secret extraction and arbitrary code execution):

  • langchain: 0.0.353 → >=0.3.0,<0.4.0
  • langchain-core: 0.1.4 → >=0.3.81,<0.4.0
  • langchain-community: 0.0.7 → >=0.3.0,<0.4.0

Upgrade tqdm to fix CVE-2024-34062 (High - CLI arguments injection via eval()):

  • tqdm: 4.66.1 → >=4.66.3

Code changes for langchain 0.3.x compatibility:

  • langchain_integration.py: Use langchain_community.chat_models (models moved from langchain.chat_models), support Pydantic v2 field introspection (model_fields/annotation) with v1 fallback
  • chat_clients.py: Import messages from langchain_core.messages instead of deprecated langchain.schema
  • rag_poisoning.py: Import Document from langchain_core.documents instead of deprecated langchain.schema
  • test_chat_clients.py: Import Field from pydantic instead of deprecated langchain_core.pydantic_v1

Also align setup.py python_requires to >=3.9 matching pyproject.toml (langchain 0.3.x requires Python 3.9+).

All 93 tests pass.

https://claude.ai/code/session_01CDFqeg5QhB4V7yQ3yVVBc9


Generated description

Below is a concise technical summary of the changes proposed in this PR:
Upgrades the LangChain ecosystem and tqdm to resolve critical security vulnerabilities while ensuring compatibility with Pydantic v2 and newer Python versions. Updates internal imports and introspection logic within the chat client and integration modules to support the migrated LangChain 0.3.x architecture.

TopicDetails
Library Compatibility Refactor imports from langchain.schema to langchain_core and update get_langchain_chat_models_info to support both Pydantic v1 and v2 field introspection.
Modified files (4)
  • ps_fuzz/attacks/rag_poisoning.py
  • ps_fuzz/chat_clients.py
  • ps_fuzz/langchain_integration.py
  • tests/test_chat_clients.py
Latest Contributors(2)
UserCommitDate
david.a@prompt.securityrag-poisoning-pr-68February 15, 2026
eliran9692@gmail.comfix-types-to-adhere-to...April 19, 2024
Security Upgrades Upgrade langchain, langchain-core, langchain-community, and tqdm to versions that mitigate known CVEs and update python_requires to 3.9.
Modified files (2)
  • pyproject.toml
  • setup.py
Latest Contributors(2)
UserCommitDate
david.a@prompt.securityrag-poisoning-pr-68February 15, 2026
vitaly@prompt.securityPROE-2074-Fix-broken-p...June 17, 2025
This pull request is reviewed by Baz. Review like a pro on (Baz).

Upgrade langchain ecosystem to 0.3.x to fix CVE-2025-68664 (CVSS 9.3
Critical - serialization injection allowing secret extraction and
arbitrary code execution):
- langchain: 0.0.353 → >=0.3.0,<0.4.0
- langchain-core: 0.1.4 → >=0.3.81,<0.4.0
- langchain-community: 0.0.7 → >=0.3.0,<0.4.0

Upgrade tqdm to fix CVE-2024-34062 (High - CLI arguments injection via
eval()):
- tqdm: 4.66.1 → >=4.66.3

Code changes for langchain 0.3.x compatibility:
- langchain_integration.py: Use langchain_community.chat_models (models
  moved from langchain.chat_models), support Pydantic v2 field
  introspection (model_fields/annotation) with v1 fallback
- chat_clients.py: Import messages from langchain_core.messages instead
  of deprecated langchain.schema
- rag_poisoning.py: Import Document from langchain_core.documents
  instead of deprecated langchain.schema
- test_chat_clients.py: Import Field from pydantic instead of
  deprecated langchain_core.pydantic_v1

Also align setup.py python_requires to >=3.9 matching pyproject.toml
(langchain 0.3.x requires Python 3.9+).

All 93 tests pass.

https://claude.ai/code/session_01CDFqeg5QhB4V7yQ3yVVBc9
@yoav-ps
Copy link

yoav-ps commented Feb 15, 2026

Baz review

@yoav-ps
Copy link

yoav-ps commented Feb 15, 2026

@baz review

@davida-ps davida-ps merged commit 17f2502 into main Feb 15, 2026
9 checks 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.

3 participants