Skip to content

Commit fffc397

Browse files
GeneAIclaude
authored andcommitted
security: Update LangChain to 1.x to fix critical vulnerabilities
Fixed 5 security vulnerabilities (3 HIGH, 1 MEDIUM + 1 HIGH RCE): - GHSA-6qv9-48xg-fc7f (HIGH): Template injection in langchain-core - GHSA-c67j-w6g6-q2cm (HIGH): Serialization injection enabling secret extraction - GHSA-m42m-m8cr-8m58 (HIGH): XXE vulnerability in langchain-text-splitters - GHSA-wwqv-p2pp-99h5 (HIGH): RCE in langgraph-checkpoint deserialization - GHSA-428g-f7cq-pgp5 (MEDIUM): DoS in marshmallow Schema.load Final dependency versions: - langchain: 0.1.0 → 1.0.0 (major upgrade) - langchain-core: 0.1.0 → 1.2.5 (both 0.3.81 and 1.2.5+ have fixes) - langchain-text-splitters: added at 0.3.9+ - langgraph: 0.1.0 → 1.0.0 (major upgrade, required for checkpoint 3.x) - langgraph-checkpoint: added at 3.0.0+ (RCE fix) - marshmallow: added at 4.1.2+ This is a major version upgrade (0.x → 1.x) due to dependency constraints. LangGraph 1.0+ requires langchain-core 1.x, which is compatible with langchain 1.x. Both 0.3.81 and 1.2.5+ contain the security patches. Breaking changes expected - comprehensive testing required. Also resolves tenacity conflict with google-genai, enabling future migration from deprecated google-generativeai. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Sonnet 4.5 <[email protected]>
1 parent e0d5619 commit fffc397

File tree

1 file changed

+21
-12
lines changed

1 file changed

+21
-12
lines changed

pyproject.toml

Lines changed: 21 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ dependencies = [
6161
anthropic = ["anthropic>=0.25.0,<1.0.0"]
6262
openai = ["openai>=1.12.0,<2.0.0"]
6363
# Note: google-generativeai is deprecated but still works; google-genai requires
64-
# tenacity>=9.1.2 which conflicts with langchain<0.3.0. Will migrate when langchain updates.
64+
# tenacity>=9.1.2 (now compatible with langchain>=0.3.0). Ready to migrate.
6565
google = ["google-generativeai>=0.3.0,<1.0.0"]
6666
llm = [
6767
"anthropic>=0.25.0,<1.0.0",
@@ -76,9 +76,12 @@ memdocs = [
7676

7777
# LangChain ecosystem for agents/workflows
7878
agents = [
79-
"langchain>=0.1.0,<0.3.0",
80-
"langchain-core>=0.1.0,<0.3.0",
81-
"langgraph>=0.1.0,<0.2.0",
79+
"langchain>=1.0.0,<2.0.0",
80+
"langchain-core>=1.2.5,<2.0.0", # 1.2.5+ has security fixes
81+
"langchain-text-splitters>=0.3.9,<0.4.0",
82+
"langgraph>=1.0.0,<2.0.0", # 1.0+ required for langgraph-checkpoint 3.0 (RCE fix)
83+
"langgraph-checkpoint>=3.0.0,<4.0.0", # Security: GHSA-wwqv-p2pp-99h5 (RCE fix)
84+
"marshmallow>=4.1.2,<5.0.0", # Security: GHSA-428g-f7cq-pgp5
8285
]
8386

8487
# CrewAI for role-based multi-agent systems
@@ -150,10 +153,13 @@ full = [
150153
"google-generativeai>=0.3.0,<1.0.0",
151154
# MemDocs integration
152155
"memdocs>=1.0.0",
153-
# Agents
154-
"langchain>=0.1.0,<0.3.0",
155-
"langchain-core>=0.1.0,<0.3.0",
156-
"langgraph>=0.1.0,<0.2.0",
156+
# Agents (updated for security fixes)
157+
"langchain>=1.0.0,<2.0.0",
158+
"langchain-core>=1.2.5,<2.0.0", # 1.2.5+ has security fixes
159+
"langchain-text-splitters>=0.3.9,<0.4.0",
160+
"langgraph>=1.0.0,<2.0.0", # 1.0+ required for langgraph-checkpoint 3.0 (RCE fix)
161+
"langgraph-checkpoint>=3.0.0,<4.0.0", # Security: GHSA-wwqv-p2pp-99h5 (RCE fix)
162+
"marshmallow>=4.1.2,<5.0.0", # Security: GHSA-428g-f7cq-pgp5
157163
# Plugins
158164
"python-docx>=0.8.11,<1.0.0",
159165
"pyyaml>=6.0,<7.0",
@@ -167,10 +173,13 @@ all = [
167173
"google-generativeai>=0.3.0,<1.0.0",
168174
# MemDocs integration
169175
"memdocs>=1.0.0",
170-
# Agents
171-
"langchain>=0.1.0,<0.3.0",
172-
"langchain-core>=0.1.0,<0.3.0",
173-
"langgraph>=0.1.0,<0.2.0",
176+
# Agents (updated for security fixes)
177+
"langchain>=1.0.0,<2.0.0",
178+
"langchain-core>=1.2.5,<2.0.0", # 1.2.5+ has security fixes
179+
"langchain-text-splitters>=0.3.9,<0.4.0",
180+
"langgraph>=1.0.0,<2.0.0", # 1.0+ required for langgraph-checkpoint 3.0 (RCE fix)
181+
"langgraph-checkpoint>=3.0.0,<4.0.0", # Security: GHSA-wwqv-p2pp-99h5 (RCE fix)
182+
"marshmallow>=4.1.2,<5.0.0", # Security: GHSA-428g-f7cq-pgp5
174183
# Plugins
175184
"python-docx>=0.8.11,<1.0.0",
176185
"pyyaml>=6.0,<7.0",

0 commit comments

Comments
 (0)