{"id":"CVE-2026-59152","aliases":["CVE-2026-59152","GHSA-f4xh-w4cj-qxq8"],"related":[],"kind":"vulnerability","state":"published","title":"Arbitrary server-side file read in LangSmith SDK TracingMiddleware","summary":"LangSmith Client SDKs provide SDK's for interacting with the LangSmith platform. Prior to 0.8.18, an attacker who can send an HTTP request to a server running the LangSmith SDK's TracingMiddleware can cause that server to read an arbitrary file from its local filesystem and upload the contents to LangSmith as a trace attachment. Depending on how the distributed trace system is deployed, triggering a read may not require authentication. Retrieving the contents requires read access to the LangSmith workspace the traces are sent to. The net effect is a trust-boundary crossing: a party with workspace trace-read access (for example a low-privilege workspace member, a contractor, or a compromised teammate account) gains the ability to read files from any server running TracingMiddleware, a capability outside that workspace's intended trust boundary. This vulnerability is fixed in 0.8.18.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"LangSmith Client SDKs provide SDK's for interacting with the LangSmith platform. Prior to 0.8.18, an attacker who can send an HTTP request to a server running the LangSmith SDK's TracingMiddleware can cause that server to read an arbitrary file from its local filesystem and upload the contents to LangSmith as a trace attachment. Depending on how the distributed trace system is deployed, triggering a read may not require authentication. Retrieving the contents requires read access to the LangSmith workspace the traces are sent to. The net effect is a trust-boundary crossing: a party with workspace trace-read access (for example a low-privilege workspace member, a contractor, or a compromised teammate account) gains the ability to read files from any server running TracingMiddleware, a capability outside that workspace's intended trust boundary. This vulnerability is fixed in 0.8.18.","source":"cvelist"},{"lang":"en","text":"# Summary\n\nAn attacker who can send an HTTP request to a server running the LangSmith SDK's `TracingMiddleware` can cause that server to read an arbitrary file from its local filesystem and upload the contents to LangSmith as a trace attachment. Depending on how the distributed trace system is deployed, triggering a read may not require authentication. Retrieving the contents requires read access to the LangSmith workspace the traces are sent to. The net effect is a trust-boundary crossing: a party with workspace trace-read access (for example a low-privilege workspace member, a contractor, or a compromised teammate account) gains the ability to read files from any server running `TracingMiddleware`, a capability outside that workspace's intended trust boundary.\n\n# Impact\n\nConfidentiality (High): arbitrary read of files accessible to the server process, exposed to anyone with workspace trace-read access.\n\n# Details\n\nTwo defects combine. A field supplied through a tracing-propagation header was merged into the run without validation, allowing injection of run attributes including attachments (CWE-346). A type check intended to gate filesystem access did not match the type of the decoded input, so the guard never engaged (CWE-843). As a result, an attacker-named file is opened by the server and uploaded as a trace attachment by the background tracing thread (CWE-22).\n\n## Who can exploit this\n\n- Anyone reachable by HTTP can trigger the file read. Depending on how the distributed trace system is deployed, triggering may not require authentication.\n- Retrieving the file contents requires read access to the destination LangSmith workspace. The upload uses the server's own configured API key and workspace, which the attacker cannot redirect, so a zero-access outsider cannot retrieve the result; a workspace member, or anyone who has compromised one, can.\n\n# Remediation\n\nUpgrade the Python SDK to `>= 0.8.18`.\n\n# Workarounds\n\nUntil upgrading, do not expose `TracingMiddleware` to untrusted HTTP traffic, and limit workspace trace-read access to trusted members.\n\n# Credits\n\nFirst reported by @Ryu7zz.","format":"markdown","source":"ghsa"},{"lang":"es","text":"Los SDK de cliente de LangSmith proporcionan SDK para interactuar con la plataforma LangSmith. Antes de la versión 0.8.18, un atacante que puede enviar una solicitud HTTP a un servidor que ejecuta el TracingMiddleware del SDK de LangSmith puede hacer que ese servidor lea un archivo arbitrario de su sistema de archivos local y cargue el contenido a LangSmith como un archivo adjunto de traza. Dependiendo de cómo se implemente el sistema de trazas distribuidas, activar una lectura puede no requerir autenticación. La recuperación del contenido requiere acceso de lectura al espacio de trabajo de LangSmith al que se envían las trazas. El efecto neto es un cruce de límite de confianza: una parte con acceso de lectura de trazas del espacio de trabajo (por ejemplo, un miembro del espacio de trabajo con privilegios bajos, un contratista o una cuenta de compañero de equipo comprometida) obtiene la capacidad de leer archivos de cualquier servidor que ejecuta TracingMiddleware, una capacidad fuera del límite de confianza previsto de ese espacio de trabajo. Esta vulnerabilidad está corregida en la versión 0.8.18.","source":"nvd"}],"published":"2026-06-19T22:10:34.000Z","modified":"2026-10-25T20:10:00.147Z","severity":{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:L/I:N/A:N","score":5,"rating":"MEDIUM"},"severities":[{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:L/I:N/A:N","score":5,"rating":"MEDIUM"},{"scorer":"GitHub","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:N/A:N","score":7.7,"rating":"HIGH"}],"cwes":["CWE-22","CWE-346","CWE-843"],"affected":[{"ranges":[{"version":"< 0.8.18","status":"affected"}],"vendor":"langchain-ai","product":"langsmith-sdk","source":"cvelist"},{"ranges":[{"type":"ecosystem","introduced":"0","status":"affected","fixed":"0.8.18"}],"ecosystem":"PyPI","package":"langsmith","purl":"pkg:pypi/langsmith","source":"ghsa"}],"references":[{"url":"https://github.com/langchain-ai/langsmith-sdk/security/advisories/GHSA-f4xh-w4cj-qxq8","tags":["web","x-refsource-confirm"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://github.com/langchain-ai/langsmith-sdk","tags":["package"],"sources":["ghsa"]}],"credits":[],"assigner":"GitHub_M","ssvc":{"scorer":"CISA-ADP","exploitation":"none","automatable":"no","technicalImpact":"partial","date":"2026-07-07T15:17:33.429Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2026-59152","url":"https://www.cve.org/CVERecord?id=CVE-2026-59152","licence":"CVE Terms of Use","modified":"2026-07-07T15:17:40.993Z"},{"source":"ghsa","name":"GitHub Advisory Database","id":"GHSA-f4xh-w4cj-qxq8","url":"https://github.com/advisories/GHSA-f4xh-w4cj-qxq8","licence":"CC-BY-4.0","modified":"2026-09-10T03:50:49.251Z"},{"source":"nvd","name":"NVD","id":"CVE-2026-59152","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-59152","licence":"Public domain","modified":"2026-10-25T20:10:00.147Z"}],"updatedAt":"2026-11-25T22:59:27.229Z","epss":{"score":0.00174,"percentile":0.07122,"date":"2026-12-01T12:00:22.000Z"}}