bpf, ktls: Fix data corruption when using bpf_msg_pop_data() in ktls
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
≥ 7246d8ed4dcce23f7509949a77be15fa9f0e3d28 · < ee03766d79de0f61ea29ffb6ab1c7b196ea1b02e| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
bpf, ktls: Fix data corruption when using bpf_msg_pop_data() in ktls
When sending plaintext data, we initially calculated the corresponding ciphertext length. However, if we later reduced the plaintext data length via socket policy, we failed to recalculate the ciphertext length.
This results in transmitting buffers containing uninitialized data during ciphertext transmission.
This causes uninitialized bytes to be appended after a complete "Application Data" packet, leading to errors on the receiving end when parsing TLS record.
From the CVE record · Linux
The Linux kernel can transmit uninitialized bytes when a BPF socket policy reduces the plaintext length during kTLS transmission without recalculating the ciphertext length. The extra bytes can cause the receiver to fail when parsing the TLS record. The input does not specify attacker access or authentication requirements.
Engineers running Linux kernels that use BPF socket policies with kTLS should check whether their kernel is affected; affected versions were not provided.