{"answers":{"affected":"2 open source packages ship an affected version, including com.alibaba:fastjson. It affects 2 products.","exploited":"There is no known exploitation of CVE-2022-25845 in the wild and no public exploit code.","fix":"Upgrade com.alibaba:fastjson to 1.2.83 or later.","what":"CVE-2022-25845 is a high-severity unsafe deserialization vulnerability in com.alibaba:fastjson, published on 10 Jun 2022. An attacker can exploit it over the internet without logging in, with no action from the victim."},"fix_prompt":"Check this codebase for CVE-2022-25845 and fix it if it is affected.\n\nWhat it is: CVE-2022-25845 is a high-severity unsafe deserialization vulnerability in com.alibaba:fastjson, published on 10 Jun 2022. An attacker can exploit it over the internet without logging in, with no action from the victim.\nExploitation: There is no known exploitation of CVE-2022-25845 in the wild and no public exploit code.\n\nAffected packages and fixed versions:\n- com.alibaba:fastjson (Maven): affected from 1.2.25; fixed in 1.2.83\n- com.alibaba:fastjson (Maven): affected from 1.2.25; fixed in 1.2.83\n\nTask:\n1. Search the dependency manifests and lockfiles (for example package.json, package-lock.json, requirements.txt, poetry.lock, uv.lock, pom.xml, build.gradle, go.mod, Cargo.lock, Gemfile.lock) and any Dockerfiles for the affected packages, including transitive dependencies.\n2. If an affected version is in use, upgrade it to the fixed version for its release line with the project's package manager, so the lockfile is regenerated. Prefer the smallest upgrade that fixes it.\n3. If there is no fix, or the upgrade would break the build, do not guess: explain the risk and the safest workaround instead.\n4. Run the tests and summarise what changed and why.\n5. If nothing in the project is affected, say so and change nothing.\n\nReference: https://insights.sbomify.com/CVE-2022-25845/ (Markdown: https://insights.sbomify.com/CVE-2022-25845/index.md)","id":"CVE-2022-25845","markdown":"https://insights.sbomify.com/CVE-2022-25845/index.md","name":"CVE-2022-25845","record":{"aliases":["GHSA-pv7h-hx5h-mgfj","SNYK-JAVA-COMALIBABA-2859222"],"analysis":{"component_type":"library","fix_type":"upgrade","impacts":["code_execution"],"network_reachable":"yes","non_default_config":true,"product_category":"Java JSON library","requires_auth":"none","summary":"Attackers can execute arbitrary code on remote servers by bypassing autoType restrictions in the fastjson library.","user_interaction":"not_required","vuln_class":"deserialization"},"analysis_generated_by":"qwen3.8-flash-next","assigner":"snyk","cpe":[{"product":"fastjson","vendor":"alibaba"},{"product":"communications_cloud_native_core_unified_data_repository","vendor":"oracle"}],"cvss":{"score":8.1,"severity":"high","source":"cna","vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H/E:P","version":"3.1"},"cwes":[{"id":"CWE-502","name":"Deserialization of Untrusted Data"}],"description":"The package com.alibaba:fastjson before 1.2.83 are vulnerable to Deserialization of Untrusted Data by bypassing the default autoType shutdown restrictions, which is possible under certain conditions. Exploiting this vulnerability allows attacking remote servers. Workaround: If upgrading is not possible, you can enable [safeMode](https://github.com/alibaba/fastjson/wiki/fastjson_safemode).","ecosystems":["Maven"],"exploits":{"exploitdb":0,"first_seen":"2023-03-01","github_poc":5,"max_poc_stars":109,"metasploit":0,"nuclei":0,"refs":[{"date":"2024-11-07T13:06:44Z","kind":"github_poc","ref":"https://github.com/luelueking/CVE-2022-25845-In-Spring","stars":109,"title":"CVE-2022-25845(fastjson1.2.80) exploit in Spring Env!"},{"date":"2024-11-26T13:03:38Z","kind":"github_poc","ref":"https://github.com/ph0ebus/CVE-2022-25845-In-Spring","stars":7,"title":"exploit by python"},{"date":"2023-03-01T16:17:08Z","kind":"github_poc","ref":"https://github.com/nerowander/CVE-2022-25845-exploit","stars":1,"title":null},{"date":"2024-01-28T20:03:23Z","kind":"github_poc","ref":"https://github.com/scabench/fastjson-tp1fn1","stars":0,"title":"a scenario based on CVE-2022-25845 yielding a TP for metadata based SCA but a FN if the callgraph is used"},{"date":"2025-07-11T07:43:50Z","kind":"github_poc","ref":"https://github.com/cuijiung/fastjson-CVE-2022-25845","stars":0,"title":null}],"tier":"poc_unverified"},"has_fix":true,"headline":"Deserialization of Untrusted Data","id":"CVE-2022-25845","indexable":true,"kev":null,"kind":"cve","links":{"ecosystem":"Maven","product":null,"products":[],"type":"deserialization","year":"2022"},"n_packages":2,"n_references":7,"next":{"headline":"Cross-site Scripting (XSS) in serve-lite","id":"CVE-2022-25847"},"packages":[{"ecosystem":"Maven","fixed":["1.2.83"],"introduced":["1.2.25"],"last_affected":[],"package":"com.alibaba:fastjson","purl":null,"source":"GHSA-pv7h-hx5h-mgfj"},{"ecosystem":"Maven","fixed":["1.2.83"],"introduced":["1.2.25"],"last_affected":[],"package":"com.alibaba:fastjson","purl":"pkg:maven/com.alibaba/fastjson","source":"GHSA-pv7h-hx5h-mgfj"}],"prev":{"headline":"Regular Expression Denial of Service (ReDoS)","id":"CVE-2022-25844"},"products":["com.alibaba:fastjson"],"published":"2022-06-10","related":[{"cvss_score":9.8,"headline":"Improper Input Validation in alilibaba:fastjson","id":"CVE-2017-18349","kev_date_added":null,"published":"2018-10-23"}],"sources":[{"class":"attribution","licence":"CVE Terms of Use (MITRE)","name":"CVE List","prefix":"CVE"},{"class":"attribution","licence":"CC BY 4.0","name":"GitHub Advisory Database","prefix":"GHSA"},{"class":"attribution","licence":"US public information, NVD API terms","name":"NVD"},{"class":"attribution","licence":"CWE Terms of Use","name":"CWE (MITRE)"},{"class":"attribution","licence":"FIRST CVSS licence","name":"CVSS (FIRST)"},{"class":"open","licence":"CC0","name":"PoC-in-GitHub"}],"ssvc":{"automatable":null,"exploitation":null,"technical_impact":null},"state":"PUBLISHED","updated":"2024-09-16","vendors":["n/a"]},"summary":"Attackers can execute arbitrary code on remote servers by bypassing autoType restrictions in the fastjson library.","url":"https://insights.sbomify.com/CVE-2022-25845/"}