HighFix available
rustc — security advisory
In the standard library in Rust before 1.51.0, the Zip implementation calls __iterator_get_unchecked() for the same index more than once when nested. This bug can lead to a memory safety violation due to an unmet safety requirement for the TrustedRandomAccess trait.
- Products
- rustc
- Affected versions
- Not specified
- Fixed versions
- 1.53.0+dfsg1-1
- CVEs
- CVE-2021-28877
- Confirmed fixed CVEs
- Not specified
- Updated in this feed
- 1 Nov 2026, 00:33 UTC · Revision 1
Source evidence
In the standard library in Rust before 1.51.0, the Zip implementation calls __iterator_get_unchecked() for the same index more than once when nested. This bug can lead to a memory safety violation due to an unmet safety requirement for the TrustedRandomAccess trait.
osv:DEBIAN-CVE-2021-28877
rustc
Fixed versions: 1.53.0+dfsg1-1
rustc
Fixed versions: 1.53.0+dfsg1-1
rustc
Fixed versions: 1.53.0+dfsg1-1
Complete source record
{
"id": "c3a1ef3d2919bb0b94c256f2c6997e848e53850b358a15d973d18aa94a615599",
"url": "https://osv.dev/vulnerability/DEBIAN-CVE-2021-28877",
"method": "structured",
"payload": {
"kind": "advisory",
"title": "DEBIAN-CVE-2021-28877",
"summary": "In the standard library in Rust before 1.51.0, the Zip implementation calls __iterator_get_unchecked() for the same index more than once when nested. This bug can lead to a memory safety violation due to an unmet safety requirement for the TrustedRandomAccess trait.",
"evidence": "osv:DEBIAN-CVE-2021-28877",
"products": [
{
"name": {
"value": "rustc",
"evidence": "/affected/0/package/name"
},
"prerequisites": [],
"fixed_versions": [
{
"value": "1.53.0+dfsg1-1",
"evidence": "/affected/0/ranges"
}
],
"affected_versions": []
},
{
"name": {
"value": "rustc",
"evidence": "/affected/1/package/name"
},
"prerequisites": [],
"fixed_versions": [
{
"value": "1.53.0+dfsg1-1",
"evidence": "/affected/1/ranges"
}
],
"affected_versions": []
},
{
"name": {
"value": "rustc",
"evidence": "/affected/2/package/name"
},
"prerequisites": [],
"fixed_versions": [
{
"value": "1.53.0+dfsg1-1",
"evidence": "/affected/2/ranges"
}
],
"affected_versions": []
}
],
"severity": "high",
"structured": {
"id": "DEBIAN-CVE-2021-28877",
"aliases": [
"DEBIAN-CVE-2021-28877"
],
"metrics": [
{
"type": "CVSS_V3",
"score": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H"
}
],
"affected": [
{
"ranges": [
{
"type": "ECOSYSTEM",
"events": [
{
"introduced": "0"
},
{
"fixed": "1.53.0+dfsg1-1"
}
]
}
],
"package": {
"name": "rustc",
"purl": "pkg:deb/debian/rustc?arch=source&distro=bookworm",
"ecosystem": "Debian:12"
},
"database_specific": {
"source": "https://storage.googleapis.com/debian-osv/debian-cve-osv/DEBIAN-CVE-2021-28877.json"
},
"ecosystem_specific": {
"urgency": "not yet assigned"
}
},
{
"ranges": [
{
"type": "ECOSYSTEM",
"events": [
{
"introduced": "0"
},
{
"fixed": "1.53.0+dfsg1-1"
}
]
}
],
"package": {
"name": "rustc",
"purl": "pkg:deb/debian/rustc?arch=source&distro=trixie",
"ecosystem": "Debian:13"
},
"database_specific": {
"source": "https://storage.googleapis.com/debian-osv/debian-cve-osv/DEBIAN-CVE-2021-28877.json"
},
"ecosystem_specific": {
"urgency": "not yet assigned"
}
},
{
"ranges": [
{
"type": "ECOSYSTEM",
"events": [
{
"introduced": "0"
},
{
"fixed": "1.53.0+dfsg1-1"
}
]
}
],
"package": {
"name": "rustc",
"purl": "pkg:deb/debian/rustc?arch=source&distro=forky",
"ecosystem": "Debian:14"
},
"database_specific": {
"source": "https://storage.googleapis.com/debian-osv/debian-cve-osv/DEBIAN-CVE-2021-28877.json"
},
"ecosystem_specific": {
"urgency": "not yet assigned"
}
}
],
"modified": "2026-10-23T18:03:25.901478345Z",
"provider": "osv",
"upstream": [
"CVE-2021-28877"
],
"references": [
"https://security-tracker.debian.org/tracker/CVE-2021-28877"
]
},
"related_cves": [
{
"value": "CVE-2021-28877",
"evidence": "/upstream"
}
],
"security_relevant": true,
"severity_evidence": "/severity/0/score"
},
"source_id": "core-osv",
"document_id": 421487,
"published_at": "2021-04-11T20:15:12.737+00:00"
}