Join the Cyber Forum: Threat Intel on May 12, 2026 to learn how AI is reshaping threat defense.Join the Virtual Cyber Forum: Threat IntelRegister Now
Experiencing a Breach?Blog
Get StartedContact Us
SentinelOne
  • Platform
    Platform Overview
    • Singularity Platform
      Welcome to Integrated Enterprise Security
    • AI for Security
      Leading the Way in AI-Powered Security Solutions
    • Securing AI
      Accelerate AI Adoption with Secure AI Tools, Apps, and Agents.
    • How It Works
      The Singularity XDR Difference
    • Singularity Marketplace
      One-Click Integrations to Unlock the Power of XDR
    • Pricing & Packaging
      Comparisons and Guidance at a Glance
    Data & AI
    • Purple AI
      Accelerate SecOps with Generative AI
    • Singularity Hyperautomation
      Easily Automate Security Processes
    • AI-SIEM
      The AI SIEM for the Autonomous SOC
    • AI Data Pipelines
      Security Data Pipeline for AI SIEM and Data Optimization
    • Singularity Data Lake
      AI-Powered, Unified Data Lake
    • Singularity Data Lake for Log Analytics
      Seamlessly Ingest Data from On-Prem, Cloud or Hybrid Environments
    Endpoint Security
    • Singularity Endpoint
      Autonomous Prevention, Detection, and Response
    • Singularity XDR
      Native & Open Protection, Detection, and Response
    • Singularity RemoteOps Forensics
      Orchestrate Forensics at Scale
    • Singularity Threat Intelligence
      Comprehensive Adversary Intelligence
    • Singularity Vulnerability Management
      Application & OS Vulnerability Management
    • Singularity Identity
      Identity Threat Detection and Response
    Cloud Security
    • Singularity Cloud Security
      Block Attacks with an AI-Powered CNAPP
    • Singularity Cloud Native Security
      Secure Cloud and Development Resources
    • Singularity Cloud Workload Security
      Real-Time Cloud Workload Protection Platform
    • Singularity Cloud Data Security
      AI-Powered Threat Detection for Cloud Storage
    • Singularity Cloud Security Posture Management
      Detect and Remediate Cloud Misconfigurations
    Securing AI
    • Prompt Security
      Secure AI Tools Across Your Enterprise
  • Why SentinelOne?
    Why SentinelOne?
    • Why SentinelOne?
      Cybersecurity Built for What’s Next
    • Our Customers
      Trusted by the World’s Leading Enterprises
    • Industry Recognition
      Tested and Proven by the Experts
    • About Us
      The Industry Leader in Autonomous Cybersecurity
    Compare SentinelOne
    • Arctic Wolf
    • Broadcom
    • CrowdStrike
    • Cybereason
    • Microsoft
    • Palo Alto Networks
    • Sophos
    • Splunk
    • Trellix
    • Trend Micro
    • Wiz
    Verticals
    • Energy
    • Federal Government
    • Finance
    • Healthcare
    • Higher Education
    • K-12 Education
    • Manufacturing
    • Retail
    • State and Local Government
  • Services
    Managed Services
    • Managed Services Overview
      Wayfinder Threat Detection & Response
    • Threat Hunting
      World-Class Expertise and Threat Intelligence
    • Managed Detection & Response
      24/7/365 Expert MDR Across Your Entire Environment
    • Incident Readiness & Response
      DFIR, Breach Readiness, & Compromise Assessments
    Support, Deployment, & Health
    • Technical Account Management
      Customer Success with Personalized Service
    • SentinelOne GO
      Guided Onboarding & Deployment Advisory
    • SentinelOne University
      Live and On-Demand Training
    • Services Overview
      Comprehensive Solutions for Seamless Security Operations
    • SentinelOne Community
      Community Login
  • Partners
    Our Network
    • MSSP Partners
      Succeed Faster with SentinelOne
    • Singularity Marketplace
      Extend the Power of S1 Technology
    • Cyber Risk Partners
      Enlist Pro Response and Advisory Teams
    • Technology Alliances
      Integrated, Enterprise-Scale Solutions
    • SentinelOne for AWS
      Hosted in AWS Regions Around the World
    • Channel Partners
      Deliver the Right Solutions, Together
    • SentinelOne for Google Cloud
      Unified, Autonomous Security Giving Defenders the Advantage at Global Scale
    • Partner Locator
      Your Go-to Source for Our Top Partners in Your Region
    Partner Portal→
  • Resources
    Resource Center
    • Case Studies
    • Data Sheets
    • eBooks
    • Reports
    • Videos
    • Webinars
    • Whitepapers
    • Events
    View All Resources→
    Blog
    • Feature Spotlight
    • For CISO/CIO
    • From the Front Lines
    • Identity
    • Cloud
    • macOS
    • SentinelOne Blog
    Blog→
    Tech Resources
    • SentinelLABS
    • Ransomware Anthology
    • Cybersecurity 101
  • About
    About SentinelOne
    • About SentinelOne
      The Industry Leader in Cybersecurity
    • Investor Relations
      Financial Information & Events
    • SentinelLABS
      Threat Research for the Modern Threat Hunter
    • Careers
      The Latest Job Opportunities
    • Press & News
      Company Announcements
    • Cybersecurity Blog
      The Latest Cybersecurity Threats, News, & More
    • FAQ
      Get Answers to Our Most Frequently Asked Questions
    • DataSet
      The Live Data Platform
    • S Foundation
      Securing a Safer Future for All
    • S Ventures
      Investing in the Next Generation of Security, Data and AI
  • Pricing
Get StartedContact Us
CVE Vulnerability Database
Vulnerability Database/CVE-2026-25640

CVE-2026-25640: Pydantic AI Path Traversal Vulnerability

CVE-2026-25640 is a path traversal flaw in Pydantic AI web UI that allows attackers to serve malicious JavaScript and steal chat history. This article covers the technical details, affected versions, impact, and mitigation.

Published: February 13, 2026

CVE-2026-25640 Overview

CVE-2026-25640 is a path traversal vulnerability in Pydantic AI, a Python agent framework used for building applications and workflows with Generative AI. The vulnerability exists in the Pydantic AI web UI component from versions 1.34.0 to before 1.51.0, allowing attackers to serve arbitrary JavaScript in the context of the application by crafting a malicious URL. This vulnerability enables theft of chat history and other client-side data when victims interact with malicious links.

Critical Impact

Attackers can execute arbitrary JavaScript in users' browsers through crafted URLs, potentially stealing sensitive chat history and client-side data from Pydantic AI web interfaces.

Affected Products

  • Pydantic AI versions 1.34.0 to 1.50.x
  • Applications using Agent.to_web to serve chat interfaces
  • CLI applications using clai web to serve chat interfaces

Discovery Timeline

  • 2026-02-06 - CVE-2026-25640 published to NVD
  • 2026-02-06 - Last updated in NVD database

Technical Details for CVE-2026-25640

Vulnerability Analysis

This path traversal vulnerability (CWE-22) affects the Pydantic AI web UI's CDN URL construction mechanism. The vulnerability stems from improper input validation of the version query parameter used to build CDN URLs. An attacker can exploit this by injecting path traversal sequences into the version parameter, causing the server to fetch and serve attacker-controlled HTML or JavaScript content from an arbitrary source on the same CDN instead of the legitimate chat UI package.

The attack requires user interaction—victims must click a malicious link or visit it via an iframe. Once triggered, attacker-controlled code executes within the victim's browser context, providing access to sensitive application data including chat history.

Root Cause

The root cause is insufficient validation of the version query parameter from the request URL. The application directly uses this parameter to construct CDN URLs without sanitizing path traversal sequences such as ../. This allows attackers to manipulate the URL path and redirect resource fetching to arbitrary locations within the CDN infrastructure.

Attack Vector

The attack is network-based and requires user interaction. An attacker crafts a malicious URL containing path traversal sequences in the version query parameter. When a victim accesses this URL—either by clicking a link or through an embedded iframe—the Pydantic AI web UI fetches and serves attacker-controlled JavaScript from an unexpected CDN location. This JavaScript then executes in the victim's browser with full access to the application context.

While these applications are typically run locally on localhost, they may also be deployed on remote servers, expanding the potential attack surface. The vulnerability specifically affects deployments using Agent.to_web or the clai web CLI command.

Detection Methods for CVE-2026-25640

Indicators of Compromise

  • Unusual URL patterns containing path traversal sequences (../) in version query parameters
  • Web server logs showing requests with manipulated CDN URLs or unexpected resource paths
  • Client-side JavaScript execution from unexpected CDN sources
  • Reports of unauthorized access to chat history or session data

Detection Strategies

  • Monitor web application logs for requests containing path traversal patterns (../, ..%2F, etc.) in query parameters
  • Implement Content Security Policy (CSP) headers to restrict JavaScript execution sources
  • Deploy web application firewalls (WAF) with rules to detect and block path traversal attempts
  • Review network traffic for anomalous CDN resource requests originating from Pydantic AI applications

Monitoring Recommendations

  • Enable detailed logging for all Pydantic AI web interface requests
  • Set up alerts for unusual patterns in version query parameters
  • Monitor for unauthorized data exfiltration attempts from client browsers
  • Regularly audit CSP configurations and JavaScript resource origins

How to Mitigate CVE-2026-25640

Immediate Actions Required

  • Upgrade Pydantic AI to version 1.51.0 or later immediately
  • Audit existing deployments using Agent.to_web or clai web for exposure
  • Implement strict Content Security Policy headers to limit JavaScript sources
  • Review access logs for evidence of exploitation attempts

Patch Information

The vulnerability has been fixed in Pydantic AI version 1.51.0. Organizations should upgrade to this version or later to remediate the vulnerability. Detailed patch information is available in the GitHub Release v1.51.0 and the GitHub Security Advisory GHSA-wjp5-868j-wqv7.

Workarounds

  • Restrict network access to Pydantic AI web interfaces to trusted users only
  • Implement a reverse proxy with URL validation to filter malicious requests before they reach the application
  • Deploy Web Application Firewall rules to block requests containing path traversal sequences
  • Disable public-facing deployments of Agent.to_web or clai web until patching is complete
bash
# Upgrade Pydantic AI to the patched version
pip install --upgrade pydantic-ai>=1.51.0

# Verify the installed version
pip show pydantic-ai | grep Version

Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

  • Vulnerability Details
  • TypePath Traversal

  • Vendor/TechPydantic

  • SeverityHIGH

  • CVSS Score7.1

  • EPSS Probability0.01%

  • Known ExploitedNo
  • CVSS Vector
  • CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:L/A:N
  • Impact Assessment
  • ConfidentialityLow
  • IntegrityLow
  • AvailabilityNone
  • CWE References
  • CWE-22
  • Technical References
  • GitHub Release v1.51.0

  • GitHub Security Advisory GHSA-wjp5-868j-wqv7
  • Related CVEs
  • CVE-2026-25904: Pydantic-AI MCP Run Python SSRF Flaw

  • CVE-2024-3772: Pydantic Regular Expression DoS Vulnerability
Default Legacy - Prefooter | Experience the World’s Most Advanced Cybersecurity Platform

Experience the World’s Most Advanced Cybersecurity Platform

See how our intelligent, autonomous cybersecurity platform can protect your organization now and into the future.

Try SentinelOne
  • Get Started
  • Get a Demo
  • Product Tour
  • Why SentinelOne
  • Pricing & Packaging
  • FAQ
  • Contact
  • Contact Us
  • Customer Support
  • SentinelOne Status
  • Language
  • Platform
  • Singularity Platform
  • Singularity Endpoint
  • Singularity Cloud
  • Singularity AI-SIEM
  • Singularity Identity
  • Singularity Marketplace
  • Purple AI
  • Services
  • Wayfinder TDR
  • SentinelOne GO
  • Technical Account Management
  • Support Services
  • Verticals
  • Energy
  • Federal Government
  • Finance
  • Healthcare
  • Higher Education
  • K-12 Education
  • Manufacturing
  • Retail
  • State and Local Government
  • Cybersecurity for SMB
  • Resources
  • Blog
  • Labs
  • Case Studies
  • Videos
  • Product Tours
  • Events
  • Cybersecurity 101
  • eBooks
  • Webinars
  • Whitepapers
  • Press
  • News
  • Ransomware Anthology
  • Company
  • About Us
  • Our Customers
  • Careers
  • Partners
  • Legal & Compliance
  • Security & Compliance
  • Investor Relations
  • S Foundation
  • S Ventures

©2026 SentinelOne, All Rights Reserved.

Privacy Notice Terms of Use

English