Medium
Out-of-bounds read in bson module of PyMongo
Type: advisorySources: OSV
An out-of-bounds read in the 'bson' module of PyMongo 4.6.2 or earlier allows deserialization of malformed BSON provided by a Server to raise an exception which may contain arbitrary application memory.
- Products
- Not specified
- Affected versions
- Not specified
- Fixed versions
- Not specified
- CVEs
- CVE-2024-5629
- Confirmed fixed CVEs
- Not specified
- Updated in this feed
- 3 Nov 2026, 10:22 UTC · Revision 1
Source evidence
Out-of-bounds read in bson module of PyMongo
core-osv · Original sourcePublished 5 Jun 2024, 14:32 UTC
An out-of-bounds read in the 'bson' module of PyMongo 4.6.2 or earlier allows deserialization of malformed BSON provided by a Server to raise an exception which may contain arbitrary application memory.
osv:CVE-2024-5629
Complete source record
{
"id": "1c567b9265731ebe22ce1ea517e4e2ddff3c08fb1d598014b99c3503681a8497",
"url": "https://osv.dev/vulnerability/CVE-2024-5629",
"method": "structured",
"payload": {
"kind": "advisory",
"title": "Out-of-bounds read in bson module of PyMongo",
"summary": "An out-of-bounds read in the 'bson' module of PyMongo 4.6.2 or earlier allows deserialization of malformed BSON provided by a Server to raise an exception which may contain arbitrary application memory.",
"evidence": "osv:CVE-2024-5629",
"products": [],
"severity": "medium",
"structured": {
"id": "CVE-2024-5629",
"aliases": [
"CVE-2024-5629",
"GHSA-m87m-mmvp-v9qm",
"PYSEC-2026-1826"
],
"metrics": [
{
"type": "CVSS_V3",
"score": "CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:C/C:L/I:N/A:L"
}
],
"affected": [
{
"ranges": [
{
"repo": "https://github.com/mongodb/mongo-python-driver",
"type": "GIT",
"events": [
{
"introduced": "0"
},
{
"fixed": "8da192f9ca2d4f6464897b22b3029c227043f0cb"
}
],
"database_specific": {
"extracted_events": [
{
"cpe": "cpe:2.3:a:mongodb:pymongo:*:*:*:*:*:*:*:*",
"range": [
{
"introduced": "0"
},
{
"fixed": "4.6.3"
}
],
"source": "CPE_RANGE"
}
]
}
}
],
"versions": [
"4.6.2",
"4.6.1",
"4.6.0",
"4.5.0",
"4.4.0",
"4.4.0b0",
"4.3.3",
"4.3.2",
"4.3.1",
"4.3.0",
"4.2.0",
"4.2.0b0",
"4.1.1",
"4.1.0",
"4.0",
"3.11.1",
"3.11.0",
"3.11.0rc0",
"3.11.0b1",
"3.11.0b0",
"3.10.1",
"3.10.0",
"3.9.0",
"3.9.0b1",
"3.9.0b0",
"3.7.0",
"3.7.0b0",
"3.6.1",
"3.6.0",
"3.6rc0",
"3.5.1",
"3.5.0",
"3.4.0",
"3.3.0",
"3.4rc0",
"3.2.2",
"3.2.1",
"3.2",
"3.2rc0",
"3.1.1",
"3.1",
"3.1rc0",
"3.0.3",
"3.0.2",
"3.0.1",
"3.0",
"3.0rc1",
"3.0rc0",
"3.0b1",
"3.0b0",
"2.7",
"2.7rc1",
"2.7rc0",
"2.6",
"2.5.1",
"2.5",
"2.4.2",
"2.4.1",
"2.4",
"2.3",
"2.3rc1",
"2.2.1",
"2.2",
"2.2rc1",
"2.1",
"2.1.1",
"2.0.1",
"2.0",
"1.11",
"1.10.1",
"1.10",
"1.9",
"1.8.1",
"1.8",
"1.7",
"1.6",
"1.5.1",
"1.5",
"1.4",
"1.3",
"1.2.1",
"1.2",
"1.1.2",
"1.1.1",
"1.1",
"1.0",
"0.16",
"0.15.2",
"0.15.1",
"0.15",
"0.14.2",
"0.14.1",
"0.14",
"0.13",
"0.12",
"0.11.3",
"0.11.2",
"0.11.1",
"0.11",
"0.10.3",
"0.10.2",
"0.10.1",
"0.10",
"0.9.5",
"0.9.4",
"0.9.3",
"0.9.2",
"0.9.1",
"0.9",
"0.8.1",
"0.8",
"0.7.2",
"0.7.1",
"0.7",
"0.6",
"0.5.3pre",
"0.5.2pre",
"0.5.1pre",
"0.5pre",
"0.4pre"
],
"database_specific": {
"source": "https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2024-5629.json"
}
}
],
"modified": "2026-10-28T02:30:27.629401690Z",
"provider": "osv",
"references": [
"https://lists.debian.org/debian-lts-announce/2024/06/msg00007.html",
"https://lists.debian.org/debian-lts-announce/2024/09/msg00032.html",
"https://github.com/CVEProject/cvelistV5/tree/main/cves/2024/5xxx/CVE-2024-5629.json",
"https://jira.mongodb.org/browse/PYTHON-4305",
"https://nvd.nist.gov/vuln/detail/CVE-2024-5629"
],
"provider_metadata": {
"cwe_ids": [
"CWE-125"
],
"cna_assigner": "mongodb",
"unresolved_ranges": [
{
"extracted_events": [
{
"range": [
{
"last_affected": "4.6.2"
}
],
"source": "AFFECTED_FIELD",
"strategy": "StandardRange"
}
]
}
],
"osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2024/5xxx/CVE-2024-5629.json"
}
},
"related_cves": [
{
"value": "CVE-2024-5629",
"evidence": "/id"
}
],
"security_relevant": true,
"severity_evidence": "/severity/0/score"
},
"source_id": "core-osv",
"document_id": 494409,
"published_at": "2024-06-05T14:32:56.435+00:00"
}