{"cve":"CVE-2024-21624","nvd":{"published":"2024-02-09T23:15:08.553","modified":"2026-06-17T07:09:52.123","status":"Modified","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.","cvss_v4":null,"cvss_v3":{"version":"3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:N/A:N","score":6.5},"cwes":["CWE-200"],"references":["https://github.com/nonebot/nonebot2/pull/2509","https://github.com/nonebot/nonebot2/security/advisories/GHSA-59j8-776v-xxxg","https://github.com/nonebot/nonebot2/pull/2509","https://github.com/nonebot/nonebot2/security/advisories/GHSA-59j8-776v-xxxg"],"products":["nonebot:nonebot"],"source":"nvd","synced_at":"2026-10-19T21:45:59.823092188+00:00"},"epss":{"cve":"CVE-2024-21624","score":0.00492,"percentile":0.42268,"date":"2026-10-31"},"kev":null,"osv":[{"id":"GHSA-59j8-776v-xxxg","url":"https://osv.dev/vulnerability/GHSA-59j8-776v-xxxg","summary":"NoneBot Potential Information Leak in User-Constructed Message Templates","modified":"2026-09-10T03:50:05.511545008Z","packages":[{"ecosystem":"PyPI","name":"nonebot2","purl":"pkg:pypi/nonebot2","ranges":[">=2.0.0a16 <2.2.0"],"fixed":["2.2.0"]}]},{"id":"PYSEC-2024-37","url":"https://osv.dev/vulnerability/PYSEC-2024-37","summary":"","modified":"2024-02-16T16:41:43.954924Z","packages":[{"ecosystem":"PyPI","name":"nonebot2","purl":"pkg:pypi/nonebot2","ranges":[">=2.0.1 <2.2.0"],"fixed":["2.2.0"]}]}],"attribution":["This product uses the NVD API but is not endorsed or certified by the NVD.","EPSS scores: FIRST Exploit Prediction Scoring System, https://www.first.org/epss","Known exploited vulnerabilities: CISA Known Exploited Vulnerabilities Catalog, https://www.cisa.gov/known-exploited-vulnerabilities-catalog","Package advisories: OSV (https://osv.dev), from the GitHub Advisory Database, PyPA, Go, RustSec and other ecosystem databases, under CC-BY 4.0 or CC0","CVE records: the CVE Program's CVE List (https://www.cve.org), under its terms of use (https://www.cve.org/Legal/TermsOfUse). CVE is a registered trademark of The MITRE Corporation; this product is not affiliated with the CVE Program."]}