# CVE-2023-52813: crypto: pcrypt - Fix hungtask for PADATA\_RESET

> Archived entry. Full-text search covers entries since 2026-11-10; exact IDs work for all years.

- **Severity:** MEDIUM 5.5
- **CVSS:** 5.5 (v3.1, NVD) `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H`
- **CVSS metrics:** Attack vector: Local; Attack complexity: Low; Privileges required: Low; User interaction: None; Scope: Unchanged; Confidentiality impact: None; Integrity impact: None; Availability impact: High
- **Exploited in the wild:** Not in CISA KEV
- **Public exploit / PoC:** None known
- **Remote exploitation:** Not remotely exploitable (local or adjacent access needed)
- **EPSS:** 0.31% (percentile 17, 2026-11-26)
- **Published:** 2024-05-21T15:31:21.604Z
- **Modified:** 2026-06-17T06:43:38.660Z

## Who should check

- Anyone running Linux \>= 16295bec6398a3eedc9377e1af6ff4c71b98c300, \< fb2d3a50a8f29a3c66682bb426144f40e32ab818; \>= 16295bec6398a3eedc9377e1af6ff4c71b98c300, \< 039fec48e062504f14845124a1a25eb199b2ddc0; \>= 16295bec6398a3eedc9377e1af6ff4c71b98c300, \< c9c1334697301c10e6918d747ed38abfbc0c96e7; \>= 16295bec6398a3eedc9377e1af6ff4c71b98c300, \< e97bf4ada7dddacd184c3e196bd063b0dc71b41d; \>= 16295bec6398a3eedc9377e1af6ff4c71b98c300, \< 546c1796ad1ed0d87dab3c4b5156d75819be2316; \>= 16295bec6398a3eedc9377e1af6ff4c71b98c300, \< c55fc098fd9d2dca475b82d00ffbcaf97879d77e; \>= 16295bec6398a3eedc9377e1af6ff4c71b98c300, \< e134f3aba98e6c801a693f540912c2d493718ddf; \>= 16295bec6398a3eedc9377e1af6ff4c71b98c300, \< 372636debe852913529b1716f44addd94fff2d28; \>= 16295bec6398a3eedc9377e1af6ff4c71b98c300, \< 8f4f68e788c3a7a696546291258bfa5fdb215523
- Anyone running Linux 2.6.34

## Description

In the Linux kernel, the following vulnerability has been resolved:

crypto: pcrypt - Fix hungtask for PADATA\_RESET

We found a hungtask bug in test\_aead\_vec\_cfg as follows:

INFO: task cryptomgr\_test:391009 blocked for more than 120 seconds.
"echo 0 \> /proc/sys/kernel/hung\_task\_timeout\_secs" disables this message.
Call trace:
 \_\_switch\_to+0x98/0xe0
 \_\_schedule+0x6c4/0xf40
 schedule+0xd8/0x1b4
 schedule\_timeout+0x474/0x560
 wait\_for\_common+0x368/0x4e0
 wait\_for\_completion+0x20/0x30
 wait\_for\_completion+0x20/0x30
 test\_aead\_vec\_cfg+0xab4/0xd50
 test\_aead+0x144/0x1f0
 alg\_test\_aead+0xd8/0x1e0
 alg\_test+0x634/0x890
 cryptomgr\_test+0x40/0x70
 kthread+0x1e0/0x220
 ret\_from\_fork+0x10/0x18
 Kernel panic - not syncing: hung\_task: blocked tasks

For padata\_do\_parallel, when the return err is 0 or -EBUSY, it will call
wait\_for\_completion(&wait-\>completion) in test\_aead\_vec\_cfg. In normal
case, aead\_request\_complete() will be called in pcrypt\_aead\_serial and the
return err is 0 for padata\_do\_parallel. But, when pinst-\>flags is
PADATA\_RESET, the return err is -EBUSY for padata\_do\_parallel, and it
won't call aead\_request\_complete(). Therefore, test\_aead\_vec\_cfg will
hung at wait\_for\_completion(&wait-\>completion), which will cause
hungtask.

The problem comes as following:
(padata\_do\_parallel)                 \|
    rcu\_read\_lock\_bh();              \|
    err = -EINVAL;                   \|   (padata\_replace)
                                     \|     pinst-\>flags \|= PADATA\_RESET;
    err = -EBUSY                     \|
    if (pinst-\>flags & PADATA\_RESET) \|
        rcu\_read\_unlock\_bh()         \|
        return err

In order to resolve the problem, we replace the return err -EBUSY with
-EAGAIN, which means parallel\_data is changing, and the caller should call
it again.

v3:
remove retry and just change the return err.
v2:
introduce padata\_try\_do\_parallel() in pcrypt\_aead\_encrypt and
pcrypt\_aead\_decrypt to solve the hungtask.

## Affected and fixed versions

- Linux: \>= 16295bec6398a3eedc9377e1af6ff4c71b98c300, \< fb2d3a50a8f29a3c66682bb426144f40e32ab818; \>= 16295bec6398a3eedc9377e1af6ff4c71b98c300, \< 039fec48e062504f14845124a1a25eb199b2ddc0; \>= 16295bec6398a3eedc9377e1af6ff4c71b98c300, \< c9c1334697301c10e6918d747ed38abfbc0c96e7; \>= 16295bec6398a3eedc9377e1af6ff4c71b98c300, \< e97bf4ada7dddacd184c3e196bd063b0dc71b41d; \>= 16295bec6398a3eedc9377e1af6ff4c71b98c300, \< 546c1796ad1ed0d87dab3c4b5156d75819be2316; \>= 16295bec6398a3eedc9377e1af6ff4c71b98c300, \< c55fc098fd9d2dca475b82d00ffbcaf97879d77e; \>= 16295bec6398a3eedc9377e1af6ff4c71b98c300, \< e134f3aba98e6c801a693f540912c2d493718ddf; \>= 16295bec6398a3eedc9377e1af6ff4c71b98c300, \< 372636debe852913529b1716f44addd94fff2d28; \>= 16295bec6398a3eedc9377e1af6ff4c71b98c300, \< 8f4f68e788c3a7a696546291258bfa5fdb215523 (cvelist)
- Linux: 2.6.34 (cvelist)

## Mitigation

- Upgrade Linux to 8f4f68e788c3a7a696546291258bfa5fdb215523 or later.

## Check your systems with an agent

Paste this into a coding agent:

```text
Check whether anything I run is affected by CVE-2023-52813. Work read-only: do not install, upgrade, delete or change anything.

Details: https://flawdb.com/CVE-2023-52813.md
Affected: Linux >= 16295bec6398a3eedc9377e1af6ff4c71b98c300, < fb2d3a50a8f29a3c66682bb426144f40e32ab818; >= 16295bec6398a3eedc9377e1af6ff4c71b98c300, < 039fec48e062504f14845124a1a25eb199b2ddc0; >= 16295bec6398a3eedc9377e1af6ff4c71b98c300, < c9c1334697301c10e6918d747ed38abfbc0c96e7; >= 16295bec6398a3eedc9377e…
Fixed in: Linux 039fec48e062504f14845124a1a25eb199b2ddc0, Linux 546c1796ad1ed0d87dab3c4b5156d75819be2316, Linux 372636debe852913529b1716f44addd94fff2d28, Linux 8f4f68e788c3a7a696546291258bfa5fdb215523

Steps:
1. Search this machine and project for Linux: dependency manifests and lockfiles, installed packages, container images and running services.
2. For each match, note the installed version and whether it is inside the affected range.
3. Report a table: location, installed version, affected (yes / no / unsure), evidence. If affected, say which fixed version or mitigation from the details link applies, but don't apply it.
```

## FAQ

### Is CVE-2023-52813 being exploited?

There is no confirmed exploitation: CVE-2023-52813 is not in the CISA Known Exploited Vulnerabilities catalog. No public exploit code is known. EPSS estimates a 0.31% chance of exploitation in the next 30 days (as of 2026-11-26).

### How serious is CVE-2023-52813?

Medium: CVSS 5.5 (v3.1, scored by NVD). Not remotely exploitable (local or adjacent access needed).

### Which versions are affected by CVE-2023-52813?

Linux \>= 16295bec6398a3eedc9377e1af6ff4c71b98c300, \< fb2d3a50a8f29a3c66682bb426144f40e32ab818; \>= 16295bec6398a3eedc9377e1af6ff4c71b98c300, \< 039fec48e062504f14845124a1a25eb199b2ddc0; \>= 16295bec6398a3eedc9377e1af6ff4c71b98c300, \< c9c1334697301c10e6918d747ed38abfbc0c96e7; \>= 16295bec6398a3eedc9377e1af6ff4c71b98c300, \< e97bf4ada7dddacd184c3e196bd063b0dc71b41d; \>= 16295bec6398a3eedc9377e1af6ff4c71b98c300, \< 546c1796ad1ed0d87dab3c4b5156d75819be2316; \>= 16295bec6398a3eedc9377e1af6ff4c71b98c300, \< c55fc098fd9d2dca475b82d00ffbcaf97879d77e; \>= 16295bec6398a3eedc9377e1af6ff4c71b98c300, \< e134f3aba98e6c801a693f540912c2d493718ddf; \>= 16295bec6398a3eedc9377e1af6ff4c71b98c300, \< 372636debe852913529b1716f44addd94fff2d28; \>= 16295bec6398a3eedc9377e1af6ff4c71b98c300, \< 8f4f68e788c3a7a696546291258bfa5fdb215523; Linux 2.6.34.

### Is there a fix for CVE-2023-52813?

Yes. Fixed in Linux 039fec48e062504f14845124a1a25eb199b2ddc0, Linux 546c1796ad1ed0d87dab3c4b5156d75819be2316, Linux 372636debe852913529b1716f44addd94fff2d28, Linux 8f4f68e788c3a7a696546291258bfa5fdb215523. Upgrade Linux to 8f4f68e788c3a7a696546291258bfa5fdb215523 or later.

### How do I check if I'm affected by CVE-2023-52813?

Find where you use the affected software (dependency lockfiles, installed packages, container images, servers) and compare the installed version with the affected range above. The agent prompt on this page does this read-only.

## References

- patch: <https://git.kernel.org/stable/c/fb2d3a50a8f29a3c66682bb426144f40e32ab818>
- patch: <https://git.kernel.org/stable/c/039fec48e062504f14845124a1a25eb199b2ddc0>
- patch: <https://git.kernel.org/stable/c/c9c1334697301c10e6918d747ed38abfbc0c96e7>
- patch: <https://git.kernel.org/stable/c/e97bf4ada7dddacd184c3e196bd063b0dc71b41d>
- patch: <https://git.kernel.org/stable/c/546c1796ad1ed0d87dab3c4b5156d75819be2316>
- patch: <https://git.kernel.org/stable/c/c55fc098fd9d2dca475b82d00ffbcaf97879d77e>
- patch: <https://git.kernel.org/stable/c/e134f3aba98e6c801a693f540912c2d493718ddf>
- patch: <https://git.kernel.org/stable/c/372636debe852913529b1716f44addd94fff2d28>
- patch: <https://git.kernel.org/stable/c/8f4f68e788c3a7a696546291258bfa5fdb215523>

## Attribution

- CVE Program: CVE® is a registered trademark of The MITRE Corporation. CVE records © 1999–2026 The MITRE Corporation. <https://www.cve.org/Legal/TermsOfUse>
- NVD: This product uses data from the NVD API but is not endorsed or certified by the NVD. <https://nvd.nist.gov/vuln/detail/CVE-2023-52813>

HTML: <https://flawdb.com/CVE-2023-52813> · JSON: <https://flawdb.com/api/v1/entries/CVE-2023-52813>
