{"answers":{"affected":"It affects 16 products.","exploited":"There is no known exploitation of CVE-2022-40540 in the wild and no public exploit code.","fix":"Apply the vendor's patch.","what":"CVE-2022-40540 is a high-severity memory corruption vulnerability in Qualcomm Sd888 5g Firmware, published on 7 Mar 2023. It can only be exploited from the same machine or local network, with no action from the victim."},"fix_prompt":"Check this codebase for CVE-2022-40540 and fix it if it is affected.\n\nWhat it is: CVE-2022-40540 is a high-severity memory corruption vulnerability in Qualcomm Sd888 5g Firmware, published on 7 Mar 2023. It can only be exploited from the same machine or local network, with no action from the victim.\nExploitation: There is no known exploitation of CVE-2022-40540 in the wild and no public exploit code.\n\nAffected product: Qualcomm Sd888 5g Firmware. No package-level version data is available, so check the vendor advisory linked from the reference page.\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-40540/ (Markdown: https://insights.sbomify.com/CVE-2022-40540/index.md)","id":"CVE-2022-40540","markdown":"https://insights.sbomify.com/CVE-2022-40540/index.md","name":"CVE-2022-40540","record":{"aliases":["3280498","A-261470730","ASB-A-261470730","GHSA-58jw-58x8-342p"],"analysis":{"component_type":"operating_system","fix_type":"patch","impacts":["code_execution","privilege_escalation"],"network_reachable":"adjacent_or_local","non_default_config":false,"product_category":"Android kernel","requires_auth":"none","summary":"A buffer overflow in the Linux kernel firmware loader allows attackers to execute arbitrary code or escalate privileges on Android devices.","user_interaction":"not_required","vuln_class":"memory_corruption"},"analysis_generated_by":"qwen3.8-flash-next","assigner":"qualcomm","cpe":[{"product":"sd888_5g_firmware","vendor":"qualcomm"},{"product":"sd_8_gen1_5g_firmware","vendor":"qualcomm"},{"product":"sw5100_firmware","vendor":"qualcomm"},{"product":"sw5100p_firmware","vendor":"qualcomm"},{"product":"wcd9380_firmware","vendor":"qualcomm"},{"product":"wcd9385_firmware","vendor":"qualcomm"},{"product":"wcn3980_firmware","vendor":"qualcomm"},{"product":"wcn3988_firmware","vendor":"qualcomm"},{"product":"wcn6850_firmware","vendor":"qualcomm"},{"product":"wcn6851_firmware","vendor":"qualcomm"},{"product":"wcn6855_firmware","vendor":"qualcomm"},{"product":"wcn6856_firmware","vendor":"qualcomm"},{"product":"wcn7850_firmware","vendor":"qualcomm"},{"product":"wcn7851_firmware","vendor":"qualcomm"},{"product":"wsa8830_firmware","vendor":"qualcomm"},{"product":"wsa8835_firmware","vendor":"qualcomm"}],"cvss":{"score":8.4,"severity":"high","source":"cna","vector":"CVSS:3.1/AV:L/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H","version":"3.1"},"cwes":[{"id":"CWE-120","name":"Buffer Copy without Checking Size of Input"}],"description":"Memory corruption due to buffer copy without checking the size of input while loading firmware in Linux Kernel.","ecosystems":[],"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 copy without checking the size of input in Linux Kernel","id":"CVE-2022-40540","indexable":true,"kev":null,"kind":"cve","links":{"ecosystem":null,"product":"qualcomm:sd888_5g_firmware","products":["qualcomm:sd888_5g_firmware","qualcomm:sd_8_gen1_5g_firmware","qualcomm:sw5100_firmware","qualcomm:sw5100p_firmware","qualcomm:wcd9380_firmware","qualcomm:wcd9385_firmware","qualcomm:wcn3980_firmware","qualcomm:wcn3988_firmware","qualcomm:wcn6850_firmware","qualcomm:wcn6851_firmware","qualcomm:wcn6855_firmware","qualcomm:wcn6856_firmware","qualcomm:wcn7850_firmware","qualcomm:wcn7851_firmware","qualcomm:wsa8830_firmware","qualcomm:wsa8835_firmware"],"type":"memory_corruption","year":"2022"},"n_packages":0,"n_references":3,"next":{"headline":"DO NOT USE THIS CANDIDATE NUMBER.","id":"CVE-2022-40541"},"packages":[],"prev":{"headline":"Improper Validation of Array Index in Automotive Android OS","id":"CVE-2022-40539"},"products":["Snapdragon"],"published":"2023-03-07","related":[{"cvss_score":9.8,"headline":"Memory corruption in Snapdragon Connectivity, Snapdragon Mobile","id":"CVE-2022-25708","kev_date_added":null,"published":"2022-09-16"},{"cvss_score":6.7,"headline":"Time-of-check Time-of-use Race Condition in Multimedia Framework","id":"CVE-2022-25716","kev_date_added":null,"published":"2023-01-06"}],"sources":[{"class":"attribution","licence":"CVE Terms of Use (MITRE)","name":"CVE List","prefix":"CVE"},{"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":null,"exploitation":null,"technical_impact":null},"state":"PUBLISHED","updated":"2024-08-03","vendors":["Qualcomm, Inc."]},"summary":"A buffer overflow in the Linux kernel firmware loader allows attackers to execute arbitrary code or escalate privileges on Android devices.","url":"https://insights.sbomify.com/CVE-2022-40540/"}