{"answers":{"affected":"3 open source packages ship an affected version, including nonebot2. It affects 1 product.","exploited":"There is no known exploitation of CVE-2024-21624 in the wild and no public exploit code.","fix":"Upgrade nonebot2 to 2.2.0 or later.","what":"CVE-2024-21624 is a medium-severity vulnerability in nonebot2, published on 9 Feb 2024. Any signed-in user can exploit it over the network, and only if a user opens a file or follows a link."},"fix_prompt":"Check this codebase for CVE-2024-21624 and fix it if it is affected.\n\nWhat it is: CVE-2024-21624 is a medium-severity vulnerability in nonebot2, published on 9 Feb 2024. Any signed-in user can exploit it over the network, and only if a user opens a file or follows a link.\nExploitation: There is no known exploitation of CVE-2024-21624 in the wild and no public exploit code.\n\nAffected packages and fixed versions:\n- nonebot2 (PyPI): affected from 2.0.0a16; fixed in 2.2.0\n- nonebot2 (PyPI): affected from 2.0.0a16; fixed in 2.2.0\n- nonebot2 (PyPI): affected from 2.0.1; fixed in 2.2.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-2024-21624/ (Markdown: https://insights.sbomify.com/CVE-2024-21624/index.md)","id":"CVE-2024-21624","markdown":"https://insights.sbomify.com/CVE-2024-21624/index.md","name":"CVE-2024-21624","record":{"aliases":["GHSA-59j8-776v-xxxg","PYSEC-2024-37"],"analysis":{"component_type":"library","fix_type":"upgrade","impacts":["data_read"],"network_reachable":"yes","non_default_config":false,"product_category":"Python chatbot framework","requires_auth":"low_privilege","summary":"Attackers can leak sensitive data like environment variables if developers improperly use user input in message templates.","user_interaction":"required","vuln_class":"information_disclosure"},"analysis_generated_by":"qwen3.8-flash-next","assigner":"GitHub_M","cpe":[{"product":"nonebot","vendor":"nonebot"}],"cvss":{"score":5.7,"severity":"medium","source":"cna","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:U/C:H/I:N/A:N","version":"3.1"},"cwes":[{"id":"CWE-200","name":"Exposure of Sensitive Information to an Unauthorized Actor"}],"description":"nonebot2 is a cross-platform Python asynchronous chatbot framework written in Python. This security advisory pertains to a potential information leak (e.g., environment variables) in instances where developers utilize `MessageTemplate` and incorporate user-provided data into templates. The identified vulnerability has been remedied in pull request #2509 and will be included in versions released from 2.2.0. Users are strongly advised to upgrade to these patched versions to safeguard against the vulnerability. A temporary workaround involves filtering underscores before incorporating user input into the message template.","ecosystems":["PyPI"],"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":"Potential Information Leak in User-Constructed Message Templates in nonebot2","id":"CVE-2024-21624","indexable":true,"kev":null,"kind":"cve","links":{"ecosystem":"PyPI","product":null,"products":[],"type":"information_disclosure","year":"2024"},"n_packages":3,"n_references":2,"next":{"headline":"One-click remote code execution via malicious deep link","id":"CVE-2024-21625"},"packages":[{"ecosystem":"PyPI","fixed":["2.2.0"],"introduced":["2.0.0a16"],"last_affected":[],"package":"nonebot2","purl":null,"source":"GHSA-59j8-776v-xxxg"},{"ecosystem":"PyPI","fixed":["2.2.0"],"introduced":["2.0.0a16"],"last_affected":[],"package":"nonebot2","purl":"pkg:pypi/nonebot2","source":"GHSA-59j8-776v-xxxg"},{"ecosystem":"PyPI","fixed":["2.2.0"],"introduced":["2.0.1"],"last_affected":[],"package":"nonebot2","purl":"pkg:pypi/nonebot2","source":"PYSEC-2024-37"}],"prev":{"headline":"Arbitrary Expression Injection in github workflow leads to Command execution \u0026 leaking secrets","id":"CVE-2024-21623"},"products":["nonebot2"],"published":"2024-02-09","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":"CC BY 4.0","name":"PyPA Advisory Database","prefix":"PYSEC"},{"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":"2024-08-01","vendors":["nonebot"]},"summary":"Attackers can leak sensitive data like environment variables if developers improperly use user input in message templates.","url":"https://insights.sbomify.com/CVE-2024-21624/"}