Server-side Request Forgery (SSRF) Affecting langsmith package, versions >=0.3.41 <0.4.6


Severity

Recommended
0.0
medium
0
10

CVSS assessment by Snyk's Security Team. Learn more

Threat Intelligence

EPSS
0.28% (20th percentile)

Do your applications use this vulnerable package?

In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.

Test your applications

Snyk Learn

Learn about Server-side Request Forgery (SSRF) vulnerabilities in an interactive lesson.

Start learning
  • Snyk IDSNYK-JS-LANGSMITH-15253025
  • published10 Feb 2026
  • disclosed9 Feb 2026
  • creditUnknown

Introduced: 9 Feb 2026

CVE-2026-25528  (opens in a new tab)
CWE-918  (opens in a new tab)

How to fix?

Upgrade langsmith to version 0.4.6 or higher.

Overview

langsmith is a Client library to connect to the LangSmith Observability and Evaluation Platform.

Affected versions of this package are vulnerable to Server-side Request Forgery (SSRF) due to the improper validation of api_url and api_key fields in baggage headers in RunTree.from_headers() and RunTree.fromHeaders() functions. An attacker can cause the exfiltration of sensitive trace data to attacker-controlled endpoints by injecting arbitrary api_url values through the baggage header, which are then used by the SDK to send run data to malicious URLs.

Note:

This issue affects applications, utilising TracingMiddleware and calling RunTree.from_headers() or RunTree.fromHeaders() with untrusted HTTP headers.

Workaround

For users that are unable to upgrade to the fixed version it is recommended:

  • To strip or validate the baggage header before passing to RunTree.from_headers() or RunTree.fromHeaders();
  • To not use TracingMiddleware with untrusted traffic.

References

CVSS Base Scores

version 4.0
version 3.1