CVE-2026-41182: LangSmith SDK: Streaming token events bypass output redaction
Summary The LangSmith SDK's output redaction controls (hideOutputs in JS, hideoutputs in Python) do not apply to streaming token events. When an LLM run produces streaming output, each chunk is recorded as a newtoken event containing the raw token value.
Published Apr 16, 2026 · Updated Apr 24, 2026
Affected packages
langsmith
- Ecosystem
- npm
- Affected
- <= 0.5.18
- Fixed in
- 0.5.19
- Check
npm ls langsmith
langsmith
- Ecosystem
- PyPI
- Affected
- <= 0.7.30
- Fixed in
- 0.7.31
- Check
pip show langsmith
Advisory details
From the GitHub Advisory Database (CC BY 4.0).
Summary
The LangSmith SDK's output redaction controls (hideOutputs in JS, hide_outputs in Python) do not apply to streaming token events. When an LLM run produces streaming output, each chunk is recorded as a new_token event containing the raw token value. These events bypass the redaction pipeline entirely — prepareRunCreateOrUpdateInputs (JS) and _hide_run_outputs (Python) only process the inputs and outputs fields on a run, never the events array. As a result, applications relying on output redaction to prevent sensitive LLM output from being stored in LangSmith will still leak the full streamed content via run events.
Details
Both JS and Python SDKs are affected. The same pattern exists in both:
- JS SDK:
traceable.ts:997-1003andtraceable.ts:1044-1050 - Python SDK:
run_helpers.py:1924andrun_helpers.py:1996
In both SDKs, new_token events with raw kwargs.token values are added during streaming, and the redaction pipeline (hideOutputs in JS, hide_outputs in Python) only processes inputs/outputs — never events.
Credited to ryu7eroo.
References
How this page is made: the data panel comes from the GitHub Advisory Database, CISA’s KEV catalog, the NVD and FIRST EPSS, and updates twice a day. No analysis has been written for this entry yet. Methodology
More LangSmith SDK vulnerabilities
All LangSmith SDK entriesGHSA-f4xh-w4cj-qxq8
LangSmith SDK TracingMiddleware: Arbitrary server-side file read
high7.7Jun 19, 2026CVE-2026-45134
LangSmith SDK: Public prompt pull deserializes untrusted manifests without trust boundary warning
high7.1May 13, 2026CVE-2026-25528
LangSmith Client SDK Affected by Server-Side Request Forgery via Tracing Header Injection
medium5.8Feb 9, 2026
