{"schemaVersion":3,"id":"CVE-2024-5998","aliases":["GHSA-f2jm-rw3h-6phg","PYSEC-2024-323","PYSEC-2026-1514"],"status":"published","duplicateOf":null,"title":null,"description":"A vulnerability in the FAISS.deserialize_from_bytes function of langchain-ai/langchain allows for pickle deserialization of untrusted data. This can lead to the execution of arbitrary commands via the os.system function. The issue affects the latest version of the product.","dates":{"published":"2024-09-17T11:50:13.813Z","modified":"2024-09-17T13:34:15.648Z","reserved":null,"kevAdded":[],"kevDue":[]},"cvss":{"headline":{"score":7.8,"severity":"high","version":"3.1","versionLabel":"v3.1","source":"NVD","vector":"CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H","computed":false,"selection":"backend-summary"},"metrics":[{"version":"3.0","versionLabel":"v3.0","source":"CVE.org","score":5.2,"severity":"medium","vector":"CVSS:3.0/AV:P/AC:L/PR:L/UI:R/S:U/C:H/I:L/A:L","exploitability":null,"impact":null,"computed":false},{"version":"4.0","versionLabel":"v4.0","source":"OSV · Pypi","score":8.4,"severity":"high","vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:A/VC:H/VI:H/VA:L/SC:N/SI:N/SA:N","exploitability":null,"impact":null,"computed":true},{"version":"3.1","versionLabel":"v3.1","source":"OSV · Pypi","score":5.2,"severity":"medium","vector":"CVSS:3.1/AV:P/AC:L/PR:L/UI:R/S:U/C:H/I:L/A:L","exploitability":1.3,"impact":7.8,"computed":true},{"version":"3.1","versionLabel":"v3.1","source":"NVD","score":7.8,"severity":"high","vector":"CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H","exploitability":null,"impact":null,"computed":false},{"version":"3.0","versionLabel":"v3.0","source":"NVD","score":5.2,"severity":"medium","vector":"CVSS:3.0/AV:P/AC:L/PR:L/UI:R/S:U/C:H/I:L/A:L","exploitability":null,"impact":null,"computed":false}]},"epss":{"probability":0.00361,"percentile":0.28416,"severity":"low","asOf":"2026-10-20T00:00:00.000Z","change":{"pp":0,"baselineDate":"2026-09-20T00:00:00.000Z","baselineScore":0.00361},"history":[{"date":"2026-09-14T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-09-15T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-09-16T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-09-17T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-09-18T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-09-19T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-09-20T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-09-21T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-09-22T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-09-23T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-09-24T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-09-25T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-09-26T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-09-27T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-09-28T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-09-29T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-09-30T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-10-01T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-10-02T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-10-03T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-10-04T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-10-05T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-10-06T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-10-07T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-10-08T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-10-09T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-10-10T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-10-11T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-10-12T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-10-13T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-10-14T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-10-15T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-10-16T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-10-17T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-10-18T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-10-19T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-10-20T00:00:00.000Z","score":0.00361,"percentile":0.28416}],"last30":[{"date":"2026-09-20T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-09-21T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-09-22T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-09-23T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-09-24T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-09-25T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-09-26T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-09-27T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-09-28T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-09-29T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-09-30T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-10-01T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-10-02T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-10-03T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-10-04T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-10-05T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-10-06T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-10-07T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-10-08T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-10-09T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-10-10T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-10-11T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-10-12T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-10-13T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-10-14T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-10-15T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-10-16T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-10-17T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-10-18T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-10-19T00:00:00.000Z","score":0.00361,"percentile":null},{"date":"2026-10-20T00:00:00.000Z","score":0.00361,"percentile":0.28416}]},"kev":{"state":"not-listed","entries":[],"listedCount":0,"totalCatalogs":3,"catalogs":[{"source":"cisa","label":"CISA","listed":false,"entry":null},{"source":"enisa","label":"ENISA","listed":false,"entry":null},{"source":"circl","label":"CIRCL","listed":false,"entry":null}]},"ransomware":{"state":"none-recorded","sources":[]},"exploits":[{"id":"REF_A82A6DC5DC47A08B","name":"Exploit Reference (huntr.com)","source":"reference","url":"https://huntr.com/bounties/fa3a2753-57c3-4e08-a176-d7a3ffda28fe","maturity":"unknown","reliabilityScore":0.2,"verified":false,"type":null,"platforms":[],"requiresAuth":null,"exploitdb":null,"metasploit":null}],"exploitCount":1,"weaknesses":[{"id":"CWE-502","name":"Deserialization of Untrusted Data","description":"The product deserializes untrusted data without sufficiently ensuring that the resulting data will be valid.","type":"weakness","status":"Draft","abstraction":"Base","likelihoodOfExploit":"Medium","url":"https://cwe.mitre.org/data/definitions/502.html"}],"affected":[{"vendor":"langchain-ai","product":"langchain-ai/langchain","name":"langchain-ai/langchain","label":"langchain-ai/langchain","ecosystem":null,"cpePart":"a","purl":null,"purlType":null,"versions":[{"text":"≥ unspecified, < 0.2.9","noFixRecorded":false,"fixedIn":null}],"versionsText":"≥ unspecified, < 0.2.9","eol":null,"hubHref":"/vendor/langchain-ai/langchain-ailangchain"},{"vendor":"langchain","product":"langchain","name":"langchain","label":"langchain","ecosystem":null,"cpePart":"a","purl":null,"purlType":null,"versions":[{"text":"< 0.2.9","noFixRecorded":false,"fixedIn":null}],"versionsText":"< 0.2.9","eol":null,"hubHref":"/vendor/langchain/langchain"},{"vendor":"PyPI","product":"langchain","name":"langchain","label":"langchain","ecosystem":"PyPI","cpePart":null,"purl":"pkg:pypi/langchain","purlType":"pypi","versions":[{"text":"< 0.2.9","noFixRecorded":false,"fixedIn":null}],"versionsText":"< 0.2.9","eol":null,"hubHref":null},{"vendor":"PyPI","product":"langchain-community","name":"langchain-community","label":"langchain-community","ecosystem":"PyPI","cpePart":null,"purl":"pkg:pypi/langchain-community","purlType":"pypi","versions":[{"text":"< 0.2.4","noFixRecorded":false,"fixedIn":null}],"versionsText":"< 0.2.4","eol":null,"hubHref":null}],"affectedCount":4,"eol":{"hasEol":false,"count":0},"references":[{"url":"https://huntr.com/bounties/fa3a2753-57c3-4e08-a176-d7a3ffda28fe","label":"huntr.com/bounties/fa3a2753-57c3-4e08-a176-d7a3ffda28fe","hostname":"huntr.com","tags":["WEB","EVIDENCE","Exploit","Third Party Advisory"]},{"url":"https://github.com/langchain-ai/langchain/commit/604dfe2d99246b0c09f047c604f0c63eafba31e7","label":"github.com/langchain-ai/langchain/commit/604dfe2d99246b0c09f047c604f0c63eafba31e7","hostname":"github.com","tags":["WEB","FIX","Patch"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2024-5998","label":"nvd.nist.gov/vuln/detail/CVE-2024-5998","hostname":"nvd.nist.gov","tags":["Advisory"]},{"url":"https://github.com/langchain-ai/langchain/commit/77209f315efd13442ec51c67719ba37dfaa44511","label":"github.com/langchain-ai/langchain/commit/77209f315efd13442ec51c67719ba37dfaa44511","hostname":"github.com","tags":["WEB"]},{"url":"https://github.com/langchain-ai/langchain","label":"github.com/langchain-ai/langchain","hostname":"github.com","tags":["PACKAGE"]},{"url":"https://pypi.org/project/langchain-community","label":"pypi.org/project/langchain-community","hostname":"pypi.org","tags":["PACKAGE"]},{"url":"https://github.com/advisories/GHSA-f2jm-rw3h-6phg","label":"github.com/advisories/GHSA-f2jm-rw3h-6phg","hostname":"github.com","tags":["Advisory"]}],"lineage":{"upstream":[],"downstream":[],"duplicates":[],"related":[]},"timeline":[{"kind":"published","date":"2024-09-17T11:50:13.813Z","label":"Published","detail":"Vulnerability first disclosed.","source":null},{"kind":"modified","date":"2024-09-17T13:34:15.648Z","label":"Last modified","detail":"Vulnerability information updated.","source":null}],"risk":{"score":41,"level":"medium","profile":"Default","thresholds":{"critical":75,"high":50,"medium":25,"low":10}},"meta":{"dataAsOf":"2026-10-20T21:02:02.812Z","stale":false,"partial":false}}