CVE-2024-21624 (GCVE-0-2024-21624)
Vulnerability from cvelistv5 – Published: 2024-02-09 22:16 – Updated: 2024-08-01 22:27
VLAI
EPSS
VEX
Title
Potential Information Leak in User-Constructed Message Templates in nonebot2
Summary
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.
Severity
5.7 (Medium)
SSVC
Exploitation: none
Automatable: no
Technical Impact: partial
CISA Coordinator · CISA-ADP (v2.0.3)
Decision recorded 2024-02-11 17:00 UTC
CWE
- CWE-200 - Exposure of Sensitive Information to an Unauthorized Actor
Assigner
References
2 references
| URL | Tags |
|---|---|
| https://github.com/nonebot/nonebot2/security/advi… | x_refsource_CONFIRM |
| https://github.com/nonebot/nonebot2/pull/2509 | x_refsource_MISC |
Impacted products
{
"containers": {
"adp": [
{
"metrics": [
{
"other": {
"content": {
"id": "CVE-2024-21624",
"options": [
{
"Exploitation": "none"
},
{
"Automatable": "no"
},
{
"Technical Impact": "partial"
}
],
"role": "CISA Coordinator",
"timestamp": "2024-02-11T17:00:54.232350Z",
"version": "2.0.3"
},
"type": "ssvc"
}
}
],
"providerMetadata": {
"dateUpdated": "2024-07-05T17:20:49.630Z",
"orgId": "134c704f-9b21-4f2e-91b3-4a467353bcc0",
"shortName": "CISA-ADP"
},
"title": "CISA ADP Vulnrichment"
},
{
"providerMetadata": {
"dateUpdated": "2024-08-01T22:27:35.692Z",
"orgId": "af854a3a-2127-422b-91ae-364da2661108",
"shortName": "CVE"
},
"references": [
{
"name": "https://github.com/nonebot/nonebot2/security/advisories/GHSA-59j8-776v-xxxg",
"tags": [
"x_refsource_CONFIRM",
"x_transferred"
],
"url": "https://github.com/nonebot/nonebot2/security/advisories/GHSA-59j8-776v-xxxg"
},
{
"name": "https://github.com/nonebot/nonebot2/pull/2509",
"tags": [
"x_refsource_MISC",
"x_transferred"
],
"url": "https://github.com/nonebot/nonebot2/pull/2509"
}
],
"title": "CVE Program Container"
}
],
"cna": {
"affected": [
{
"product": "nonebot2",
"vendor": "nonebot",
"versions": [
{
"status": "affected",
"version": "\u003e= 2.0.0a16, \u003c 2.2.0"
}
]
}
],
"descriptions": [
{
"lang": "en",
"value": "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."
}
],
"metrics": [
{
"cvssV3_1": {
"attackComplexity": "LOW",
"attackVector": "NETWORK",
"availabilityImpact": "NONE",
"baseScore": 5.7,
"baseSeverity": "MEDIUM",
"confidentialityImpact": "HIGH",
"integrityImpact": "NONE",
"privilegesRequired": "LOW",
"scope": "UNCHANGED",
"userInteraction": "REQUIRED",
"vectorString": "CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:U/C:H/I:N/A:N",
"version": "3.1"
}
}
],
"problemTypes": [
{
"descriptions": [
{
"cweId": "CWE-200",
"description": "CWE-200: Exposure of Sensitive Information to an Unauthorized Actor",
"lang": "en",
"type": "CWE"
}
]
}
],
"providerMetadata": {
"dateUpdated": "2024-02-09T22:16:49.974Z",
"orgId": "a0819718-46f1-4df5-94e2-005712e83aaa",
"shortName": "GitHub_M"
},
"references": [
{
"name": "https://github.com/nonebot/nonebot2/security/advisories/GHSA-59j8-776v-xxxg",
"tags": [
"x_refsource_CONFIRM"
],
"url": "https://github.com/nonebot/nonebot2/security/advisories/GHSA-59j8-776v-xxxg"
},
{
"name": "https://github.com/nonebot/nonebot2/pull/2509",
"tags": [
"x_refsource_MISC"
],
"url": "https://github.com/nonebot/nonebot2/pull/2509"
}
],
"source": {
"advisory": "GHSA-59j8-776v-xxxg",
"discovery": "UNKNOWN"
},
"title": "Potential Information Leak in User-Constructed Message Templates in nonebot2"
}
},
"cveMetadata": {
"assignerOrgId": "a0819718-46f1-4df5-94e2-005712e83aaa",
"assignerShortName": "GitHub_M",
"cveId": "CVE-2024-21624",
"datePublished": "2024-02-09T22:16:49.974Z",
"dateReserved": "2023-12-29T03:00:44.953Z",
"dateUpdated": "2024-08-01T22:27:35.692Z",
"state": "PUBLISHED"
},
"dataType": "CVE_RECORD",
"dataVersion": "5.1",
"vulnerability-lookup:meta": {
"epss": {
"cve": "CVE-2024-21624",
"date": "2026-11-02",
"epss": "0.00492",
"percentile": "0.42248"
},
"nvd": {
"cve": {
"affected": [
{
"affectedData": [
{
"product": "nonebot2",
"vendor": "nonebot",
"versions": [
{
"status": "affected",
"version": "\u003e= 2.0.0a16, \u003c 2.2.0"
}
]
}
],
"source": "security-advisories@github.com"
}
],
"configurations": [
{
"nodes": [
{
"cpeMatch": [
{
"criteria": "cpe:2.3:a:nonebot:nonebot:*:*:*:*:*:*:*:*",
"matchCriteriaId": "48D76A37-92D4-435B-8E50-798D10E7E452",
"versionEndExcluding": "2.2.0",
"versionStartIncluding": "2.0.1",
"vulnerable": true
},
{
"criteria": "cpe:2.3:a:nonebot:nonebot:2.0.0:-:*:*:*:*:*:*",
"matchCriteriaId": "465F6B52-66C6-4227-9EDE-CE2B532DF86F",
"vulnerable": true
},
{
"criteria": "cpe:2.3:a:nonebot:nonebot:2.0.0:alpha16:*:*:*:*:*:*",
"matchCriteriaId": "E33D41DF-25CA-475D-A068-ABB2BB8F0756",
"vulnerable": true
},
{
"criteria": "cpe:2.3:a:nonebot:nonebot:2.0.0:beta1:*:*:*:*:*:*",
"matchCriteriaId": "6C2A7A44-E383-4FC5-9471-7F7D142EE5B5",
"vulnerable": true
},
{
"criteria": "cpe:2.3:a:nonebot:nonebot:2.0.0:beta2:*:*:*:*:*:*",
"matchCriteriaId": "97E334E2-1BBD-49F4-9DB6-6030539246B5",
"vulnerable": true
},
{
"criteria": "cpe:2.3:a:nonebot:nonebot:2.0.0:beta3:*:*:*:*:*:*",
"matchCriteriaId": "A73B180B-3EC8-4050-8E2F-F879097D5349",
"vulnerable": true
},
{
"criteria": "cpe:2.3:a:nonebot:nonebot:2.0.0:beta4:*:*:*:*:*:*",
"matchCriteriaId": "A4940243-0FAD-46CB-83AD-28D131B0C33D",
"vulnerable": true
},
{
"criteria": "cpe:2.3:a:nonebot:nonebot:2.0.0:beta5:*:*:*:*:*:*",
"matchCriteriaId": "882E455A-7665-4E87-A000-24F3BAD30574",
"vulnerable": true
},
{
"criteria": "cpe:2.3:a:nonebot:nonebot:2.0.0:rc1:*:*:*:*:*:*",
"matchCriteriaId": "3735223E-557B-4B99-849F-EA965A478B12",
"vulnerable": true
},
{
"criteria": "cpe:2.3:a:nonebot:nonebot:2.0.0:rc2:*:*:*:*:*:*",
"matchCriteriaId": "4AE1E1EC-D01B-41ED-8268-2725C67E92EC",
"vulnerable": true
},
{
"criteria": "cpe:2.3:a:nonebot:nonebot:2.0.0:rc3:*:*:*:*:*:*",
"matchCriteriaId": "00EAA913-619A-4999-866C-BC7F44E84FA9",
"vulnerable": true
},
{
"criteria": "cpe:2.3:a:nonebot:nonebot:2.0.0:rc4:*:*:*:*:*:*",
"matchCriteriaId": "E3411B5D-14F4-4BA0-AF2A-CBF789F5BEE9",
"vulnerable": true
}
],
"negate": false,
"operator": "OR"
}
]
}
],
"cveTags": [],
"descriptions": [
{
"lang": "en",
"value": "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."
},
{
"lang": "es",
"value": "nonebot2 es un framework de chatbot asincr\u00f3nico de Python multiplataforma escrito en Python. Este aviso de seguridad se refiere a una posible fuga de informaci\u00f3n (por ejemplo, variables de entorno) en casos en los que los desarrolladores utilizan \"MessageTemplate\" e incorporan datos proporcionados por el usuario en plantillas. La vulnerabilidad identificada se solucion\u00f3 en la solicitud de extracci\u00f3n n.\u00b0 2509 y se incluir\u00e1 en las versiones lanzadas a partir de la 2.2.0. Se recomienda encarecidamente a los usuarios que actualicen a estas versiones parcheadas para protegerse contra la vulnerabilidad. Una soluci\u00f3n temporal implica filtrar los guiones bajos antes de incorporar la entrada del usuario en la plantilla del mensaje."
}
],
"id": "CVE-2024-21624",
"lastModified": "2026-06-17T07:09:52.123",
"metrics": {
"cvssMetricV31": [
{
"cvssData": {
"attackComplexity": "LOW",
"attackVector": "NETWORK",
"availabilityImpact": "NONE",
"baseScore": 5.7,
"baseSeverity": "MEDIUM",
"confidentialityImpact": "HIGH",
"integrityImpact": "NONE",
"privilegesRequired": "LOW",
"scope": "UNCHANGED",
"userInteraction": "REQUIRED",
"vectorString": "CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:U/C:H/I:N/A:N",
"version": "3.1"
},
"exploitabilityScore": 2.1,
"impactScore": 3.6,
"source": "security-advisories@github.com",
"type": "Secondary"
},
{
"cvssData": {
"attackComplexity": "LOW",
"attackVector": "NETWORK",
"availabilityImpact": "NONE",
"baseScore": 6.5,
"baseSeverity": "MEDIUM",
"confidentialityImpact": "HIGH",
"integrityImpact": "NONE",
"privilegesRequired": "NONE",
"scope": "UNCHANGED",
"userInteraction": "REQUIRED",
"vectorString": "CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:N/A:N",
"version": "3.1"
},
"exploitabilityScore": 2.8,
"impactScore": 3.6,
"source": "nvd@nist.gov",
"type": "Primary"
}
],
"ssvcV203": [
{
"source": "134c704f-9b21-4f2e-91b3-4a467353bcc0",
"ssvcData": {
"id": "CVE-2024-21624",
"options": [
{
"exploitation": "none"
},
{
"automatable": "no"
},
{
"technicalImpact": "partial"
}
],
"role": "CISA Coordinator",
"timestamp": "2024-02-11T17:00:54.232350Z",
"version": "2.0.3"
}
}
]
},
"published": "2024-02-09T23:15:08.553",
"references": [
{
"source": "security-advisories@github.com",
"tags": [
"Issue Tracking",
"Patch"
],
"url": "https://github.com/nonebot/nonebot2/pull/2509"
},
{
"source": "security-advisories@github.com",
"tags": [
"Vendor Advisory"
],
"url": "https://github.com/nonebot/nonebot2/security/advisories/GHSA-59j8-776v-xxxg"
},
{
"source": "af854a3a-2127-422b-91ae-364da2661108",
"tags": [
"Issue Tracking",
"Patch"
],
"url": "https://github.com/nonebot/nonebot2/pull/2509"
},
{
"source": "af854a3a-2127-422b-91ae-364da2661108",
"tags": [
"Vendor Advisory"
],
"url": "https://github.com/nonebot/nonebot2/security/advisories/GHSA-59j8-776v-xxxg"
}
],
"sourceIdentifier": "security-advisories@github.com",
"vulnStatus": "Modified",
"weaknesses": [
{
"description": [
{
"lang": "en",
"value": "CWE-200"
}
],
"source": "security-advisories@github.com",
"type": "Secondary"
},
{
"description": [
{
"lang": "en",
"value": "NVD-CWE-noinfo"
}
],
"source": "nvd@nist.gov",
"type": "Primary"
}
]
}
},
"redhat_vex": {
"current_release_date": "2025-05-28T21:46:38+00:00",
"cve": "CVE-2024-21624",
"id": "CVE-2024-21624",
"initial_release_date": "2024-01-01T00:00:00+00:00",
"product_status:known_not_affected": "1",
"source": "Red Hat CSAF VEX",
"status": "final",
"title": "Potential Information Leak in User-Constructed Message Templates in nonebot2",
"url": "https://security.access.redhat.com/data/csaf/v2/vex/2024/cve-2024-21624.json",
"version": "3"
},
"vulnrichment": {
"containers": {
"adp": [
{
"providerMetadata": {
"dateUpdated": "2024-08-01T22:27:35.692Z",
"orgId": "af854a3a-2127-422b-91ae-364da2661108",
"shortName": "CVE"
},
"references": [
{
"name": "https://github.com/nonebot/nonebot2/security/advisories/GHSA-59j8-776v-xxxg",
"tags": [
"x_refsource_CONFIRM",
"x_transferred"
],
"url": "https://github.com/nonebot/nonebot2/security/advisories/GHSA-59j8-776v-xxxg"
},
{
"name": "https://github.com/nonebot/nonebot2/pull/2509",
"tags": [
"x_refsource_MISC",
"x_transferred"
],
"url": "https://github.com/nonebot/nonebot2/pull/2509"
}
],
"title": "CVE Program Container"
},
{
"metrics": [
{
"other": {
"content": {
"id": "CVE-2024-21624",
"options": [
{
"Exploitation": "none"
},
{
"Automatable": "no"
},
{
"Technical Impact": "partial"
}
],
"role": "CISA Coordinator",
"timestamp": "2024-02-11T17:00:54.232350Z",
"version": "2.0.3"
},
"type": "ssvc"
}
}
],
"providerMetadata": {
"dateUpdated": "2024-07-05T15:20:36.919Z",
"orgId": "134c704f-9b21-4f2e-91b3-4a467353bcc0",
"shortName": "CISA-ADP"
},
"title": "CISA ADP Vulnrichment"
}
],
"cna": {
"affected": [
{
"product": "nonebot2",
"vendor": "nonebot",
"versions": [
{
"status": "affected",
"version": "\u003e= 2.0.0a16, \u003c 2.2.0"
}
]
}
],
"descriptions": [
{
"lang": "en",
"value": "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."
}
],
"metrics": [
{
"cvssV3_1": {
"attackComplexity": "LOW",
"attackVector": "NETWORK",
"availabilityImpact": "NONE",
"baseScore": 5.7,
"baseSeverity": "MEDIUM",
"confidentialityImpact": "HIGH",
"integrityImpact": "NONE",
"privilegesRequired": "LOW",
"scope": "UNCHANGED",
"userInteraction": "REQUIRED",
"vectorString": "CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:U/C:H/I:N/A:N",
"version": "3.1"
}
}
],
"problemTypes": [
{
"descriptions": [
{
"cweId": "CWE-200",
"description": "CWE-200: Exposure of Sensitive Information to an Unauthorized Actor",
"lang": "en",
"type": "CWE"
}
]
}
],
"providerMetadata": {
"dateUpdated": "2024-02-09T22:16:49.974Z",
"orgId": "a0819718-46f1-4df5-94e2-005712e83aaa",
"shortName": "GitHub_M"
},
"references": [
{
"name": "https://github.com/nonebot/nonebot2/security/advisories/GHSA-59j8-776v-xxxg",
"tags": [
"x_refsource_CONFIRM"
],
"url": "https://github.com/nonebot/nonebot2/security/advisories/GHSA-59j8-776v-xxxg"
},
{
"name": "https://github.com/nonebot/nonebot2/pull/2509",
"tags": [
"x_refsource_MISC"
],
"url": "https://github.com/nonebot/nonebot2/pull/2509"
}
],
"source": {
"advisory": "GHSA-59j8-776v-xxxg",
"discovery": "UNKNOWN"
},
"title": "Potential Information Leak in User-Constructed Message Templates in nonebot2"
}
},
"cveMetadata": {
"assignerOrgId": "a0819718-46f1-4df5-94e2-005712e83aaa",
"assignerShortName": "GitHub_M",
"cveId": "CVE-2024-21624",
"datePublished": "2024-02-09T22:16:49.974Z",
"dateReserved": "2023-12-29T03:00:44.953Z",
"dateUpdated": "2024-08-01T22:27:35.692Z",
"state": "PUBLISHED"
},
"dataType": "CVE_RECORD",
"dataVersion": "5.1"
}
}
}
Loading…
Loading…
Drag nodes to arrange them. Double-click a related vulnerability to open it, or a source to visit its link. The Physics button on the left tunes the layout and the simulation; the legend at the bottom left hides or shows nodes by kind and by sighting type.
Experimental. This forecast is provided for visualization only and may change without notice. Do not use it for operational decisions.
Forecast uses a logistic model when the trend is rising, or an exponential decay model when the trend is falling. Fitted via linearized least squares.
Sightings
| Author | Source | Type | Date | Other |
|---|
Nomenclature
- Seen: The vulnerability was mentioned, discussed, or observed by the user.
- Confirmed: The vulnerability has been validated from an analyst's perspective.
- Published Proof of Concept: A public proof of concept is available for this vulnerability.
- Exploited: The vulnerability was observed as exploited by the user who reported the sighting.
- Patched: The vulnerability was observed as successfully patched by the user who reported the sighting.
- Not exploited: The vulnerability was not observed as exploited by the user who reported the sighting.
- Not confirmed: The user expressed doubt about the validity of the vulnerability.
- Not patched: The vulnerability was not observed as successfully patched by the user who reported the sighting.
Vulnerability timeline
Sightings and recorded dates, grouped by day · UTC
Loading timeline…
Loading…
Loading…
The MITRE ATT&CK techniques below are AI-generated suggestions, inferred from the description of the
vulnerability by the CIRCL/vulnerability-attack-technique-classification-roberta-base
model, served locally by ML-Gateway.
They have not been verified by an analyst and are provided for guidance only.
The approach is described in our paper Mapping CVEs to MITRE ATT&CK Techniques: A Curated Gold-Set Classifier and the Limits of LLM-Assisted Label Expansion.
Browse all ATT&CK techniques and the vulnerabilities related to each.
The approach is described in our paper Mapping CVEs to MITRE ATT&CK Techniques: A Curated Gold-Set Classifier and the Limits of LLM-Assisted Label Expansion.
Browse all ATT&CK techniques and the vulnerabilities related to each.
Loading…
Related by attack behaviour
Vulnerabilities whose description is nearest to this one in the vector space of the CIRCL/vulnerability-attack-technique-biencoder model. This is a similarity search over the bi-encoder space (plain cosine), not a classification, and it has no measured accuracy.