CVE-2026-43492 (GCVE-0-2026-43492)
Vulnerability from cvelistv5 – Published: 2026-05-19 10:44 – Updated: 2026-05-19 10:44
VLAI?
Title
lib/crypto: mpi: Fix integer underflow in mpi_read_raw_from_sgl()
Summary
In the Linux kernel, the following vulnerability has been resolved:
lib/crypto: mpi: Fix integer underflow in mpi_read_raw_from_sgl()
Yiming reports an integer underflow in mpi_read_raw_from_sgl() when
subtracting "lzeros" from the unsigned "nbytes".
For this to happen, the scatterlist "sgl" needs to occupy more bytes
than the "nbytes" parameter and the first "nbytes + 1" bytes of the
scatterlist must be zero. Under these conditions, the while loop
iterating over the scatterlist will count more zeroes than "nbytes",
subtract the number of zeroes from "nbytes" and cause the underflow.
When commit 2d4d1eea540b ("lib/mpi: Add mpi sgl helpers") originally
introduced the bug, it couldn't be triggered because all callers of
mpi_read_raw_from_sgl() passed a scatterlist whose length was equal to
"nbytes".
However since commit 63ba4d67594a ("KEYS: asymmetric: Use new crypto
interface without scatterlists"), the underflow can now actually be
triggered. When invoking a KEYCTL_PKEY_ENCRYPT system call with a
larger "out_len" than "in_len" and filling the "in" buffer with zeroes,
crypto_akcipher_sync_prep() will create an all-zero scatterlist used for
both the "src" and "dst" member of struct akcipher_request and thereby
fulfil the conditions to trigger the bug:
sys_keyctl()
keyctl_pkey_e_d_s()
asymmetric_key_eds_op()
software_key_eds_op()
crypto_akcipher_sync_encrypt()
crypto_akcipher_sync_prep()
crypto_akcipher_encrypt()
rsa_enc()
mpi_read_raw_from_sgl()
To the user this will be visible as a DoS as the kernel spins forever,
causing soft lockup splats as a side effect.
Fix it.
Severity ?
No CVSS data available.
Assigner
References
Impacted products
2 products
| Vendor | Product | Version | |
|---|---|---|---|
| Linux | Linux |
Affected:
2d4d1eea540b27c72488fd1914674c42473d53df , < 2aa77a18dc7f2670497fe3ee5acbeda0b57659e5
(git)
Affected: 2d4d1eea540b27c72488fd1914674c42473d53df , < 26d3a97ad46c7a9226ec04d4bf35bd4998a97d16 (git) Affected: 2d4d1eea540b27c72488fd1914674c42473d53df , < 8637dfb4c1d8a7026ef681f2477c6de8b71c4003 (git) Affected: 2d4d1eea540b27c72488fd1914674c42473d53df , < 30e513e755bb381afce6fb57cdc8694136193f22 (git) Affected: 2d4d1eea540b27c72488fd1914674c42473d53df , < 8c2f1288250a90a4b5cabed5d888d7e3aeed4035 (git) |
|
| Linux | Linux |
Affected:
4.4
Unaffected: 0 , < 4.4 (semver) Unaffected: 6.6.140 , ≤ 6.6.* (semver) Unaffected: 6.12.88 , ≤ 6.12.* (semver) Unaffected: 6.18.30 , ≤ 6.18.* (semver) Unaffected: 7.0.7 , ≤ 7.0.* (semver) Unaffected: 7.1-rc1 , ≤ * (original_commit_for_fix) |
{
"containers": {
"cna": {
"affected": [
{
"defaultStatus": "unaffected",
"product": "Linux",
"programFiles": [
"lib/crypto/mpi/mpicoder.c"
],
"repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
"vendor": "Linux",
"versions": [
{
"lessThan": "2aa77a18dc7f2670497fe3ee5acbeda0b57659e5",
"status": "affected",
"version": "2d4d1eea540b27c72488fd1914674c42473d53df",
"versionType": "git"
},
{
"lessThan": "26d3a97ad46c7a9226ec04d4bf35bd4998a97d16",
"status": "affected",
"version": "2d4d1eea540b27c72488fd1914674c42473d53df",
"versionType": "git"
},
{
"lessThan": "8637dfb4c1d8a7026ef681f2477c6de8b71c4003",
"status": "affected",
"version": "2d4d1eea540b27c72488fd1914674c42473d53df",
"versionType": "git"
},
{
"lessThan": "30e513e755bb381afce6fb57cdc8694136193f22",
"status": "affected",
"version": "2d4d1eea540b27c72488fd1914674c42473d53df",
"versionType": "git"
},
{
"lessThan": "8c2f1288250a90a4b5cabed5d888d7e3aeed4035",
"status": "affected",
"version": "2d4d1eea540b27c72488fd1914674c42473d53df",
"versionType": "git"
}
]
},
{
"defaultStatus": "affected",
"product": "Linux",
"programFiles": [
"lib/crypto/mpi/mpicoder.c"
],
"repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
"vendor": "Linux",
"versions": [
{
"status": "affected",
"version": "4.4"
},
{
"lessThan": "4.4",
"status": "unaffected",
"version": "0",
"versionType": "semver"
},
{
"lessThanOrEqual": "6.6.*",
"status": "unaffected",
"version": "6.6.140",
"versionType": "semver"
},
{
"lessThanOrEqual": "6.12.*",
"status": "unaffected",
"version": "6.12.88",
"versionType": "semver"
},
{
"lessThanOrEqual": "6.18.*",
"status": "unaffected",
"version": "6.18.30",
"versionType": "semver"
},
{
"lessThanOrEqual": "7.0.*",
"status": "unaffected",
"version": "7.0.7",
"versionType": "semver"
},
{
"lessThanOrEqual": "*",
"status": "unaffected",
"version": "7.1-rc1",
"versionType": "original_commit_for_fix"
}
]
}
],
"cpeApplicability": [
{
"nodes": [
{
"cpeMatch": [
{
"criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
"versionEndExcluding": "6.6.140",
"versionStartIncluding": "4.4",
"vulnerable": true
},
{
"criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
"versionEndExcluding": "6.12.88",
"versionStartIncluding": "4.4",
"vulnerable": true
},
{
"criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
"versionEndExcluding": "6.18.30",
"versionStartIncluding": "4.4",
"vulnerable": true
},
{
"criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
"versionEndExcluding": "7.0.7",
"versionStartIncluding": "4.4",
"vulnerable": true
},
{
"criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
"versionEndExcluding": "7.1-rc1",
"versionStartIncluding": "4.4",
"vulnerable": true
}
],
"negate": false,
"operator": "OR"
}
]
}
],
"descriptions": [
{
"lang": "en",
"value": "In the Linux kernel, the following vulnerability has been resolved:\n\nlib/crypto: mpi: Fix integer underflow in mpi_read_raw_from_sgl()\n\nYiming reports an integer underflow in mpi_read_raw_from_sgl() when\nsubtracting \"lzeros\" from the unsigned \"nbytes\".\n\nFor this to happen, the scatterlist \"sgl\" needs to occupy more bytes\nthan the \"nbytes\" parameter and the first \"nbytes + 1\" bytes of the\nscatterlist must be zero. Under these conditions, the while loop\niterating over the scatterlist will count more zeroes than \"nbytes\",\nsubtract the number of zeroes from \"nbytes\" and cause the underflow.\n\nWhen commit 2d4d1eea540b (\"lib/mpi: Add mpi sgl helpers\") originally\nintroduced the bug, it couldn\u0027t be triggered because all callers of\nmpi_read_raw_from_sgl() passed a scatterlist whose length was equal to\n\"nbytes\".\n\nHowever since commit 63ba4d67594a (\"KEYS: asymmetric: Use new crypto\ninterface without scatterlists\"), the underflow can now actually be\ntriggered. When invoking a KEYCTL_PKEY_ENCRYPT system call with a\nlarger \"out_len\" than \"in_len\" and filling the \"in\" buffer with zeroes,\ncrypto_akcipher_sync_prep() will create an all-zero scatterlist used for\nboth the \"src\" and \"dst\" member of struct akcipher_request and thereby\nfulfil the conditions to trigger the bug:\n\n sys_keyctl()\n keyctl_pkey_e_d_s()\n asymmetric_key_eds_op()\n software_key_eds_op()\n crypto_akcipher_sync_encrypt()\n crypto_akcipher_sync_prep()\n crypto_akcipher_encrypt()\n rsa_enc()\n mpi_read_raw_from_sgl()\n\nTo the user this will be visible as a DoS as the kernel spins forever,\ncausing soft lockup splats as a side effect.\n\nFix it."
}
],
"providerMetadata": {
"dateUpdated": "2026-05-19T10:44:24.719Z",
"orgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
"shortName": "Linux"
},
"references": [
{
"url": "https://git.kernel.org/stable/c/2aa77a18dc7f2670497fe3ee5acbeda0b57659e5"
},
{
"url": "https://git.kernel.org/stable/c/26d3a97ad46c7a9226ec04d4bf35bd4998a97d16"
},
{
"url": "https://git.kernel.org/stable/c/8637dfb4c1d8a7026ef681f2477c6de8b71c4003"
},
{
"url": "https://git.kernel.org/stable/c/30e513e755bb381afce6fb57cdc8694136193f22"
},
{
"url": "https://git.kernel.org/stable/c/8c2f1288250a90a4b5cabed5d888d7e3aeed4035"
}
],
"title": "lib/crypto: mpi: Fix integer underflow in mpi_read_raw_from_sgl()",
"x_generator": {
"engine": "bippy-1.2.0"
}
}
},
"cveMetadata": {
"assignerOrgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
"assignerShortName": "Linux",
"cveId": "CVE-2026-43492",
"datePublished": "2026-05-19T10:44:24.719Z",
"dateReserved": "2026-05-01T14:12:56.013Z",
"dateUpdated": "2026-05-19T10:44:24.719Z",
"state": "PUBLISHED"
},
"dataType": "CVE_RECORD",
"dataVersion": "5.2",
"vulnerability-lookup:meta": {
"epss": {
"cve": "CVE-2026-43492",
"date": "2026-05-20",
"epss": "0.00018",
"percentile": "0.04886"
},
"nvd": "{\"cve\":{\"id\":\"CVE-2026-43492\",\"sourceIdentifier\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\",\"published\":\"2026-05-19T12:16:18.880\",\"lastModified\":\"2026-05-19T12:16:18.880\",\"vulnStatus\":\"Received\",\"cveTags\":[],\"descriptions\":[{\"lang\":\"en\",\"value\":\"In the Linux kernel, the following vulnerability has been resolved:\\n\\nlib/crypto: mpi: Fix integer underflow in mpi_read_raw_from_sgl()\\n\\nYiming reports an integer underflow in mpi_read_raw_from_sgl() when\\nsubtracting \\\"lzeros\\\" from the unsigned \\\"nbytes\\\".\\n\\nFor this to happen, the scatterlist \\\"sgl\\\" needs to occupy more bytes\\nthan the \\\"nbytes\\\" parameter and the first \\\"nbytes + 1\\\" bytes of the\\nscatterlist must be zero. Under these conditions, the while loop\\niterating over the scatterlist will count more zeroes than \\\"nbytes\\\",\\nsubtract the number of zeroes from \\\"nbytes\\\" and cause the underflow.\\n\\nWhen commit 2d4d1eea540b (\\\"lib/mpi: Add mpi sgl helpers\\\") originally\\nintroduced the bug, it couldn\u0027t be triggered because all callers of\\nmpi_read_raw_from_sgl() passed a scatterlist whose length was equal to\\n\\\"nbytes\\\".\\n\\nHowever since commit 63ba4d67594a (\\\"KEYS: asymmetric: Use new crypto\\ninterface without scatterlists\\\"), the underflow can now actually be\\ntriggered. When invoking a KEYCTL_PKEY_ENCRYPT system call with a\\nlarger \\\"out_len\\\" than \\\"in_len\\\" and filling the \\\"in\\\" buffer with zeroes,\\ncrypto_akcipher_sync_prep() will create an all-zero scatterlist used for\\nboth the \\\"src\\\" and \\\"dst\\\" member of struct akcipher_request and thereby\\nfulfil the conditions to trigger the bug:\\n\\n sys_keyctl()\\n keyctl_pkey_e_d_s()\\n asymmetric_key_eds_op()\\n software_key_eds_op()\\n crypto_akcipher_sync_encrypt()\\n crypto_akcipher_sync_prep()\\n crypto_akcipher_encrypt()\\n rsa_enc()\\n mpi_read_raw_from_sgl()\\n\\nTo the user this will be visible as a DoS as the kernel spins forever,\\ncausing soft lockup splats as a side effect.\\n\\nFix it.\"}],\"metrics\":{},\"references\":[{\"url\":\"https://git.kernel.org/stable/c/26d3a97ad46c7a9226ec04d4bf35bd4998a97d16\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\"},{\"url\":\"https://git.kernel.org/stable/c/2aa77a18dc7f2670497fe3ee5acbeda0b57659e5\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\"},{\"url\":\"https://git.kernel.org/stable/c/30e513e755bb381afce6fb57cdc8694136193f22\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\"},{\"url\":\"https://git.kernel.org/stable/c/8637dfb4c1d8a7026ef681f2477c6de8b71c4003\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\"},{\"url\":\"https://git.kernel.org/stable/c/8c2f1288250a90a4b5cabed5d888d7e3aeed4035\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\"}]}}"
}
}
Loading…
Loading…
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.
Loading…
Loading…