{"answers":{"affected":"2 open source packages ship an affected version, including workerd. It affects 1 product.","exploited":"There is no known exploitation of CVE-2023-2512 in the wild and no public exploit code.","fix":"Upgrade workerd to 1.20230419.0 or later.","what":"CVE-2023-2512 is a medium-severity vulnerability in Cloudflare workerd, published on 12 May 2023. An attacker can exploit it over the internet without logging in, with no action from the victim."},"fix_prompt":"Check this codebase for CVE-2023-2512 and fix it if it is affected.\n\nWhat it is: CVE-2023-2512 is a medium-severity vulnerability in Cloudflare workerd, published on 12 May 2023. 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-2023-2512 in the wild and no public exploit code.\n\nAffected packages and fixed versions:\n- workerd (npm): affected all versions; fixed in 1.20230419.0\n- workerd (npm): affected all versions; fixed in 1.20230419.0\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-2023-2512/ (Markdown: https://insights.sbomify.com/CVE-2023-2512/index.md)","id":"CVE-2023-2512","markdown":"https://insights.sbomify.com/CVE-2023-2512/index.md","name":"CVE-2023-2512","record":{"aliases":["GHSA-8vx6-69vg-c46f"],"analysis":{"component_type":"server_software","fix_type":"upgrade","impacts":["denial_of_service","code_execution"],"network_reachable":"yes","non_default_config":false,"product_category":"Cloudflare workerd runtime","requires_auth":"none","summary":"An integer overflow in workerd's FormData API can cause memory corruption and crashes when processing extremely large forms, requiring a runtime upgrade.","user_interaction":"not_required","vuln_class":"integer_overflow"},"analysis_generated_by":"qwen3.8-flash-next","assigner":"cloudflare","cpe":[{"product":"workerd","vendor":"cloudflare"}],"cvss":{"score":6.5,"severity":"medium","source":"cna","vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:L/I:N/A:H","version":"3.1"},"cwes":[{"id":"CWE-190","name":"Integer Overflow or Wraparound"},{"id":"CWE-125","name":"Out-of-bounds Read"}],"description":"Prior to version v1.20230419.0, the FormData API implementation was subject to an integer overflow. If a FormData instance contained more than 2^31 elements, the forEach() method could end up reading from the wrong location in memory while iterating over elements. This would most likely lead to a segmentation fault, but could theoretically allow arbitrary undefined behavior.\n\nIn order for the bug to be exploitable, the process would need to be able to allocate 160GB of RAM. Due to this, the bug was never exploitable on the Cloudflare Workers platform, but could theoretically be exploitable on deployments of workerd running on machines with a huge amount of memory. Moreover, in order to be remotely exploited, an attacker would have to upload a single form-encoded HTTP request of at least tens of gigabytes in size. The application code would then have to use request.formData() to parse the request and formData.forEach() to iterate over this data. Due to these limitations, the exploitation likelihood was considered Low.\n\nA fix that addresses this vulnerability has been released in version v1.20230419.0 and users are encouraged to update to the latest version available.","ecosystems":["npm"],"exploits":{"exploitdb":0,"first_seen":null,"github_poc":0,"max_poc_stars":null,"metasploit":0,"nuclei":0,"refs":[],"tier":"none_known"},"has_fix":true,"headline":"Buffer under-read in workerd","id":"CVE-2023-2512","indexable":true,"kev":null,"kind":"cve","links":{"ecosystem":"npm","product":null,"products":[],"type":"integer_overflow","year":"2023"},"n_packages":2,"n_references":2,"next":{"headline":"Use after free in Linux kernel ext4 filesystem","id":"CVE-2023-2513"},"packages":[{"ecosystem":"npm","fixed":["1.20230419.0"],"introduced":["0"],"last_affected":[],"package":"workerd","purl":null,"source":"GHSA-8vx6-69vg-c46f"},{"ecosystem":"npm","fixed":["1.20230419.0"],"introduced":["0"],"last_affected":[],"package":"workerd","purl":"pkg:npm/workerd","source":"GHSA-8vx6-69vg-c46f"}],"prev":{"headline":"DO NOT USE THIS CANDIDATE NUMBER.","id":"CVE-2023-2511"},"products":["workerd"],"published":"2023-05-12","related":[],"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)"}],"ssvc":{"automatable":"no","exploitation":"none","technical_impact":"partial"},"state":"PUBLISHED","updated":"2025-01-24","vendors":["Cloudflare"]},"summary":"An integer overflow in workerd's FormData API can cause memory corruption and crashes when processing extremely large forms, requiring a runtime upgrade.","url":"https://insights.sbomify.com/CVE-2023-2512/"}