net/sched: act_mirred: don't override retval if we already lost the skb
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
≥ e5cf1baf92cb785b90390db1c624948e70c8b8bd · < 166c2c8a6a4dc2e4ceba9e10cfe81c3e469e3210| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
net/sched: act_mirred: don't override retval if we already lost the skb
If we're redirecting the skb, and haven't called tcf_mirred_forward(), yet, we need to tell the core to drop the skb by setting the retcode to SHOT. If we have called tcf_mirred_forward(), however, the skb is out of our hands and returning SHOT will lead to UaF.
Move the retval override to the error path which actually need it.
From the CVE record · Linux
The Linux kernel’s net/sched act_mirred component can return SHOT after forwarding a packet buffer it no longer owns, leading to a use-after-free. The input does not specify how an attacker could reach this condition or whether authentication or user interaction is required.
Engineers running the Linux kernel should check their versions; the input does not identify affected versions.