net: dsa: sja1105: flower: reject cross-chip redirect
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
≥ dfacc5a23e227cabdff41b6202f510398e90d36b · < abd7511e12b231798332afa04ed9bee9e84f9445| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
net: dsa: sja1105: flower: reject cross-chip redirect
dsa_port_from_netdev() may return a valid port from a different switch chip. Programming another chip's port index into the local hardware causes redirection to the wrong port, or an out-of-bounds access if the index exceeds the local chip's port count.
Apply a minimal fix that adds a check to catch this case and adjusts the extack message. When cls->common.skip_sw is not set, the operation could instead redirect to the upstream port and let the software or upstream switch(es) handle the forward, but that is not addressed here.
From the CVE record · Linux
The Linux kernel's sja1105 flower handling may accept a redirect to a port on a different switch chip. This can redirect traffic to the wrong port or cause an out-of-bounds access if the port index exceeds the local chip's port count. The input does not specify attacker access requirements or user interaction.
Engineers running Linux kernels with the sja1105 switch driver should check whether their kernel is affected; affected versions are not specified.