crypto: af_alg - limit RX SG extraction by receive buffer budget
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
≥ e870456d8e7c8d57c059ea479b5aadbb55ff4c3a · < 8eceab19eba9dcbfd2a0daec72e1bf48aa100170| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
crypto: af_alg - limit RX SG extraction by receive buffer budget
Make af_alg_get_rsgl() limit each RX scatterlist extraction to the remaining receive buffer budget.
af_alg_get_rsgl() currently uses af_alg_readable() only as a gate before extracting data into the RX scatterlist. Limit each extraction to the remaining af_alg_rcvbuf(sk) budget so that receive-side accounting matches the amount of data attached to the request.
If skcipher cannot obtain enough RX space for at least one chunk while more data remains to be processed, reject the recvmsg call instead of rounding the request length down to zero.
From the CVE record · Linux
The Linux kernel's af_alg receive path can extract more data into an RX scatterlist than the remaining receive-buffer budget permits. A caller using recvmsg can encounter incorrect receive-side accounting; for skcipher, insufficient RX space can also cause a request length to be rounded down to zero instead of rejected. The input does not specify authentication requirements or user interaction.
Engineers running Linux kernels should check whether their kernel includes the affected af_alg code; affected versions are not specified.