The SentinelOne Annual Threat Report - A Defenders Guide from the FrontlinesThe SentinelOne Annual Threat ReportGet the Report
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-40190

CVE-2026-40190: LangSmith SDK Prototype Pollution Flaw

CVE-2026-40190 is a prototype pollution vulnerability in LangSmith JavaScript/TypeScript SDK affecting versions prior to 0.5.18. Attackers can pollute Object.prototype via constructor.prototype traversal. This article covers technical details, affected versions, impact, and mitigation strategies.

Published: April 17, 2026

CVE-2026-40190 Overview

CVE-2026-40190 is a prototype pollution vulnerability affecting the LangSmith JavaScript/TypeScript SDK (langsmith). The vulnerability exists in the SDK's internally vendored lodashset() utility, where an incomplete fix for prototype pollution allows attackers to pollute Object.prototype through the constructor.prototype traversal path. Prior to version 0.5.18, the baseAssignValue() function only guards against the __proto__ key but fails to prevent alternative prototype pollution vectors.

Critical Impact

An attacker who controls keys in data processed by the createAnonymizer() API can pollute Object.prototype, affecting all objects in the Node.js process. This can lead to application-wide security issues including denial of service, authorization bypass, or in some cases remote code execution.

Affected Products

  • LangSmith JavaScript/TypeScript SDK (langsmith) versions prior to 0.5.18
  • Applications using the createAnonymizer() API with user-controlled input

Discovery Timeline

  • April 10, 2026 - CVE-2026-40190 published to NVD
  • April 13, 2026 - Last updated in NVD database

Technical Details for CVE-2026-40190

Vulnerability Analysis

This vulnerability is classified as CWE-1321 (Improperly Controlled Modification of Object Prototype Attributes), commonly known as prototype pollution. The root issue stems from an incomplete security fix in the vendored lodash library's set() utility function.

Prototype pollution vulnerabilities occur when attackers can inject properties into JavaScript's base object prototypes. In this case, while the baseAssignValue() function was patched to block direct access via __proto__, it failed to account for the semantically equivalent constructor.prototype path. This oversight allows attackers to bypass the existing protection and still achieve prototype pollution.

The attack surface is specifically through the createAnonymizer() API, which processes data containing keys controlled by external input. When malicious keys containing constructor.prototype paths are processed, the vulnerable set() function allows these properties to be written to Object.prototype.

Root Cause

The root cause is an incomplete security fix in the vendored lodashset() utility. The baseAssignValue() function implements a blocklist approach that only filters the __proto__ key, but JavaScript provides multiple equivalent paths to access an object's prototype. The constructor.prototype path achieves the same result and was not included in the blocklist, creating a bypass for the existing protection.

Attack Vector

The attack requires network access and involves an attacker providing malicious input containing specially crafted keys to an application using the LangSmith SDK's createAnonymizer() API. When this API processes the attacker-controlled data, the vulnerable set() function traverses the key path and writes to Object.prototype.

The attack mechanism involves crafting JSON objects with keys like constructor.prototype.polluted that, when processed by the vulnerable function, add properties to all JavaScript objects in the Node.js process. This can lead to various impacts depending on how the application uses object properties, including authentication bypass, denial of service, or in severe cases, code execution.

For technical details and proof-of-concept information, refer to the GitHub Security Advisory.

Detection Methods for CVE-2026-40190

Indicators of Compromise

  • Presence of unexpected properties on Object.prototype in the Node.js runtime
  • Application logs showing unusual key names containing constructor.prototype in API requests
  • Unexpected behavior in object property checks or iterations across the application
  • Error conditions triggered by polluted prototype properties affecting application logic

Detection Strategies

  • Review application logs for requests containing constructor, prototype, or __proto__ in JSON keys
  • Implement runtime monitoring to detect modifications to built-in prototypes
  • Use static analysis tools to identify usage of vulnerable LangSmith SDK versions
  • Deploy dependency scanning to flag langsmith packages prior to version 0.5.18

Monitoring Recommendations

  • Enable verbose logging for the createAnonymizer() API to track input data patterns
  • Implement application-level monitoring for prototype modifications using Object.freeze() on critical prototypes in development
  • Monitor for anomalous application behavior that could indicate prototype pollution exploitation
  • Set up alerts for dependency vulnerabilities in CI/CD pipelines

How to Mitigate CVE-2026-40190

Immediate Actions Required

  • Upgrade the LangSmith JavaScript/TypeScript SDK (langsmith) to version 0.5.18 or later immediately
  • Audit application code for usage of createAnonymizer() with user-controlled input
  • Implement input validation to reject keys containing constructor, prototype, or __proto__ paths
  • Review application logs for evidence of exploitation attempts

Patch Information

The vulnerability is fixed in LangSmith SDK version 0.5.18. The fix addresses the incomplete prototype pollution protection in the vendored lodashset() utility by extending the blocklist to include the constructor.prototype traversal path. Organizations should update their package.json or package-lock.json to require langsmith version >=0.5.18.

For additional details on the fix, refer to the GitHub Security Advisory.

Workarounds

  • Implement input sanitization to strip or reject keys containing constructor or prototype before passing data to createAnonymizer()
  • Use Object.freeze(Object.prototype) in application startup to prevent prototype modifications (may cause compatibility issues with some libraries)
  • Implement a wrapper function around createAnonymizer() that validates and sanitizes input keys
  • Consider using --frozen-intrinsics Node.js flag in production environments to prevent prototype modifications
bash
# Update langsmith to patched version
npm update langsmith@0.5.18

# Or specify minimum version in package.json
# "langsmith": ">=0.5.18"

# Verify installed version
npm list langsmith

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

  • Vulnerability Details
  • TypeOther

  • Vendor/TechLangsmith

  • SeverityMEDIUM

  • CVSS Score5.6

  • EPSS Probability0.05%

  • Known ExploitedNo
  • CVSS Vector
  • CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:L/I:L/A:L
  • Impact Assessment
  • ConfidentialityHigh
  • IntegrityNone
  • AvailabilityLow
  • CWE References
  • CWE-1321
  • Technical References
  • GitHub Security Advisory
  • Related CVEs
  • CVE-2026-41182: LangSmith SDK Information Disclosure Bug

  • CVE-2026-25750: LangSmith Auth Bypass Vulnerability

  • CVE-2026-25528: LangSmith Client SDKs SSRF 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