Source

Linux kernel race condition corrupts state in AF_ALG sockets

High CISA KEV Public exploit CWE-362

Summary

The Linux kernel's AF_ALG crypto socket interface is affected: concurrent writes to the same socket can corrupt its internal state, which could lead to kernel memory corruption, data disclosure, privilege escalation or a crash. An attacker needs local access with a low-privileged account and no user interaction, reaching the bug through AF_ALG socket calls, and attacks using this flaw are happening.

Details

In the Linux kernel, the following vulnerability has been resolved: crypto: af_alg - Disallow concurrent writes in af_alg_sendmsg Issuing two writes to the same af_alg socket is bogus as the data will be interleaved in an unpredictable fashion. Furthermore, concurrent writes may create inconsistencies in the internal socket state. Disallow this by adding a new ctx->write field that indiciates exclusive ownership for writing.

Affected

Affects Linux kernels from 2.6.38 that use the AF_ALG crypto socket interface, where two concurrent writes to one socket corrupt its internal state. Fixed in 5.10.245, 5.15.194, 6.1.154, 6.6.108, 6.12.49 and 6.16.9.

Suggested Fix

Upgrade to 5.10.245, 5.15.194, 6.1.154, 6.6.108, 6.12.49, 6.16.9.

References