CVE-2026-31533: net/tls: fix use-after-free in -EBUSY error path of tls_do_encryption

Published Apr 23, 2026
·
Updated

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

net/tls: fix use-after-free in -EBUSY error path of tlsdoencryption

The -EBUSY handling in tlsdoencryption(), introduced by commit 859054147318 ("net: tls: handle backlogging of crypto requests"), has a use-after-free due to double cleanup of encryptpending and the scatterlist entry.

When cryptoaeadencrypt() returns -EBUSY, the request is enqueued to the cryptd backlog and the async callback tlsencryptdone() will be invoked upon completion. That callback unconditionally restores the scatterlist entry (sge->offset, sge->length) and decrements ctx->encryptpending. However, if tlsencryptasyncwait() returns an error, the synchronous error path in tlsdoencryption() performs the same cleanup again, double-decrementing encryptpending and double-restoring the scatterlist.

The double-decrement corrupts the encryptpending sentinel (initialized to 1), making tlsencryptasyncwait() permanently skip the wait for pending async callbacks. A subsequent sendmsg can then free the tlsrec via bpfexectxverdict() while a cryptd callback is still pending, resulting in a use-after-free when the callback fires on the freed record.

Fix this by skipping the synchronous cleanup when the -EBUSY async wait returns an error, since the callback has already handled encryptpending and sge restoration.

Affected Software

18 affected componentsFixes available
Linux Linux kernel
Linux Linux kernel>=5.15.160<5.15.203
Linux Linux kernel>=6.1.84<6.1.169
Linux Linux kernel>=6.6.18<6.6.135
Linux Linux kernel>=6.7.6<6.8
Linux Linux kernel>=6.8.1<6.12.82
Linux Linux kernel>=6.13<6.18.23
Linux Linux kernel>=6.19<6.19.13
Linux Linux kernel=7.0-rc1
Linux Linux kernel=7.0-rc2
Linux Linux kernel=7.0-rc3
Linux Linux kernel=7.0-rc4
Linux Linux kernel=7.0-rc5
Linux Linux kernel=7.0-rc6
Linux Linux kernel=7.0-rc7
Microsoft azl3 kernel 6.6.134.1-2
debian/linux
5.10.223-15.10.257-16.1.170-36.1.174-16.12.86-16.12.90-27.0.10-1
debian/linux-6.1
6.1.174-1~deb11u1

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade debian/linux to a version that resolves this vulnerability.

    Fixed in 5.10.223-1Fixed in 5.10.257-1Fixed in 6.1.170-3Fixed in 6.1.174-1Fixed in 6.12.86-1Fixed in 6.12.90-2Fixed in 7.0.10-1
  2. Upgrade

    Upgrade debian/linux-6.1 to a version that resolves this vulnerability.

    Fixed in 6.1.174-1~deb11u1
  3. Upgrade

    Upgrade Linux kernel net/tls to a version that resolves this vulnerability.

    Patch 859054147318

Event History

Apr 23, 2026
CVE Published
via MITRE·03:11 PM
Data Sourced
via MITRE·03:11 PM
DescriptionSeverity
Data Sourced
via NVD·06:16 PM
RemedyDescriptionSeverityWeaknessAffected Software
May 1, 2026
Data Sourced
via Microsoft·08:01 AM
DescriptionSeverityWeaknessAffected Software
Updated
via Microsoft·08:01 AM
DescriptionSeverity
Jun 5, 2026
Data Sourced
via Debian·08:54 PM
DescriptionAffected Software
Jun 6, 2026
Data Sourced
via Ubuntu·08:54 PM
RemedyDescriptionSeverityAffected Software
Free Weekly Intel

Don't miss critical vulnerabilities

Join thousands of security professionals who receive our weekly digest of trending CVEs, zero-days, and exploited vulnerabilities.

No spam. Unsubscribe anytime.

Frequently Asked Questions

1

What is the severity of CVE-2026-31533?

CVE-2026-31533 has been classified as a high severity vulnerability due to the potential for misuse of freed memory.

2

How do I fix CVE-2026-31533?

To fix CVE-2026-31533, update the Linux kernel to a version that includes the patch for the use-after-free vulnerability.

3

What affected software is impacted by CVE-2026-31533?

CVE-2026-31533 affects the Linux kernel specifically.

4

What type of vulnerability is CVE-2026-31533?

CVE-2026-31533 is classified as a use-after-free vulnerability in the TLS encryption handling code.

5

What is the impact of CVE-2026-31533 on system security?

The impact of CVE-2026-31533 could lead to potential unauthorized access or crashes due to memory misuse.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203