{"id":"CVE-2024-47658","state":"PUBLISHED","title":"crypto: stm32/cryp - call finalize with bh disabled","description":"In the Linux kernel, the following vulnerability has been resolved:\n\ncrypto: stm32/cryp - call finalize with bh disabled\n\nThe finalize operation in interrupt mode produce a produces a spinlock\nrecursion warning. The reason is the fact that BH must be disabled\nduring this process.","publishedAt":"2024-10-09T14:02:53.230Z","updatedAt":"2026-10-30T12:19:26.566Z","severity":{"score":7.5,"label":"High","version":"3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H","source":"Linux"},"assigner":"Linux","products":["Linux Linux"],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"9e054ec21ef8344345b28603fb272fe999f735db","status":"affected","lessThan":"d16983c48f922ef46fb154b52a5b7eed2e689eae","versionType":"git"},{"version":"9e054ec21ef8344345b28603fb272fe999f735db","status":"affected","lessThan":"d93a2f86b0a998aa1f0870c85a2a60a0771ef89a","versionType":"git"},{"version":"9e054ec21ef8344345b28603fb272fe999f735db","status":"affected","lessThan":"5d734665cd5d93270731e0ff1dd673fec677f447","versionType":"git"},{"version":"9e054ec21ef8344345b28603fb272fe999f735db","status":"affected","lessThan":"56ddb9aa3b324c2d9645b5a7343e46010cf3f6ce","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["drivers/crypto/stm32/stm32-cryp.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"4.16","status":"affected"},{"version":"0","status":"unaffected","lessThan":"4.16","versionType":"semver"},{"version":"6.1.191","status":"unaffected","lessThanOrEqual":"6.1.*","versionType":"semver"},{"version":"6.6.50","status":"unaffected","lessThanOrEqual":"6.6.*","versionType":"semver"},{"version":"6.10.9","status":"unaffected","lessThanOrEqual":"6.10.*","versionType":"semver"},{"version":"6.11","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["drivers/crypto/stm32/stm32-cryp.c"]}],"references":["https://git.kernel.org/stable/c/d16983c48f922ef46fb154b52a5b7eed2e689eae","https://git.kernel.org/stable/c/d93a2f86b0a998aa1f0870c85a2a60a0771ef89a","https://git.kernel.org/stable/c/5d734665cd5d93270731e0ff1dd673fec677f447","https://git.kernel.org/stable/c/56ddb9aa3b324c2d9645b5a7343e46010cf3f6ce"],"weaknesses":[],"ingestedAt":"2026-10-30T12:36:04.432Z","source":{"repository":"CVEProject/cvelistV5","path":"cves/2024/47xxx/CVE-2024-47658.json","commit":"db8103c5921aac81d5d90efcf3745980dafabf49","baselineCommit":"556c9d3a8cd17e218bb8e452ba7cd619a384ff47"},"raw":{"dataType":"CVE_RECORD","dataVersion":"5.2","cveMetadata":{"cveId":"CVE-2024-47658","state":"PUBLISHED","datePublished":"2024-10-09T14:02:53.230Z","dateUpdated":"2026-10-30T12:19:26.566Z","assignerShortName":"Linux","assignerOrgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateReserved":"2024-09-30T16:00:12.935Z"},"containers":{"cna":{"title":"crypto: stm32/cryp - call finalize with bh disabled","descriptions":[{"lang":"en","value":"In the Linux kernel, the following vulnerability has been resolved:\n\ncrypto: stm32/cryp - call finalize with bh disabled\n\nThe finalize operation in interrupt mode produce a produces a spinlock\nrecursion warning. The reason is the fact that BH must be disabled\nduring this process."}],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"9e054ec21ef8344345b28603fb272fe999f735db","status":"affected","lessThan":"d16983c48f922ef46fb154b52a5b7eed2e689eae","versionType":"git"},{"version":"9e054ec21ef8344345b28603fb272fe999f735db","status":"affected","lessThan":"d93a2f86b0a998aa1f0870c85a2a60a0771ef89a","versionType":"git"},{"version":"9e054ec21ef8344345b28603fb272fe999f735db","status":"affected","lessThan":"5d734665cd5d93270731e0ff1dd673fec677f447","versionType":"git"},{"version":"9e054ec21ef8344345b28603fb272fe999f735db","status":"affected","lessThan":"56ddb9aa3b324c2d9645b5a7343e46010cf3f6ce","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["drivers/crypto/stm32/stm32-cryp.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"4.16","status":"affected"},{"version":"0","status":"unaffected","lessThan":"4.16","versionType":"semver"},{"version":"6.1.191","status":"unaffected","lessThanOrEqual":"6.1.*","versionType":"semver"},{"version":"6.6.50","status":"unaffected","lessThanOrEqual":"6.6.*","versionType":"semver"},{"version":"6.10.9","status":"unaffected","lessThanOrEqual":"6.10.*","versionType":"semver"},{"version":"6.11","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["drivers/crypto/stm32/stm32-cryp.c"]}],"references":[{"url":"https://git.kernel.org/stable/c/d16983c48f922ef46fb154b52a5b7eed2e689eae"},{"url":"https://git.kernel.org/stable/c/d93a2f86b0a998aa1f0870c85a2a60a0771ef89a"},{"url":"https://git.kernel.org/stable/c/5d734665cd5d93270731e0ff1dd673fec677f447"},{"url":"https://git.kernel.org/stable/c/56ddb9aa3b324c2d9645b5a7343e46010cf3f6ce"}],"metrics":[{"cvssV3_1":{"version":"3.1","vectorString":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H","baseScore":7.5,"baseSeverity":"HIGH"},"scenarios":[{"lang":"en","value":"AV:N - The damaging consequence is reached through the IPsec ESP receive path — a remote peer's ESP packets drive `esp_input()`, whose completion callback `esp_input_done` → `xfrm_input_resume()` is invoked by the stm32-cryp threaded IRQ handler with BH enabled. The upstream engine check that this driver violates was itself added after the same failure was hit with network traffic (iperf over IPsec).\nAC:L - The BH-enabled completion happens on every interrupt-mode request, and the recursion requires only that a NET_RX softirq land on the same CPU while `x->lock` is held — a window the attacker widens at will by sustaining ESP packet volume, controlling both sides of the race. The original reporter reproduced it with ordinary iperf load.\nPR:N - No credentials on the target are needed: ESP frames sent to a known SPI enter `esp_input()` and reach `esp_input_done` even when authentication fails, and ordinary tunnel traffic from any remote host suffices. The alternate local vector via AF_ALG is likewise available to a fully unprivileged user.\nUI:N - Triggering requires only sending network traffic to a device whose IPsec/crypto operations are backed by the STM32 CRYP accelerator; no action by any local user or administrator is involved.\nS:U - The fault is a locking-context violation contained entirely within the kernel; no VM, IOMMU, or sandbox boundary is crossed and no other security authority is affected.\nC:N - The defect is an incorrect execution context for a completion callback, not a memory-safety error — there is no out-of-bounds read, no freed-object reuse, and no path by which attacker-readable data is exposed.\nI:N - No memory is corrupted and no attacker-controlled write primitive arises; the callback simply runs with bottom halves enabled, which affects serialization rather than data content.\nA:H - Recursive acquisition of `xfrm_state->lock` from the re-entered `xfrm_input()` produces a spinlock-recursion BUG and a hard deadlock on that CPU, hanging IPsec/network processing (and panicking outright under `panic_on_warn`)."}]}],"providerMetadata":{"shortName":"Linux","orgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateUpdated":"2026-10-30T12:19:26.566Z"},"cpeApplicability":[{"nodes":[{"operator":"OR","negate":false,"cpeMatch":[{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"4.16","versionEndExcluding":"6.1.191"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"4.16","versionEndExcluding":"6.6.50"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"4.16","versionEndExcluding":"6.10.9"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"4.16","versionEndExcluding":"6.11"}]}]}],"x_generator":{"engine":"bippy-1.2.0"}},"adp":[{"title":"CISA ADP Vulnrichment","metrics":[{"other":{"type":"ssvc","content":{"timestamp":"2024-10-10T13:23:47.545736Z","id":"CVE-2024-47658","options":[{"Exploitation":"none"},{"Automatable":"no"},{"Technical Impact":"partial"}],"role":"CISA Coordinator","version":"2.0.3"}}}],"providerMetadata":{"shortName":"CISA-ADP","orgId":"134c704f-9b21-4f2e-91b3-4a467353bcc0","dateUpdated":"2024-10-10T13:24:01.773Z"}}]}}}