can: bcm: add missing rcu list annotations and operations
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
≥ dac5e6249159ac255dad9781793dbe5908ac9ddb · < b06a4a397ac826603f39875cb7c7819a41365196| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
can: bcm: add missing rcu list annotations and operations
sashiko-bot remarked the missing use of list_add_rcu() in bcm_[rx|tx]_setup() to have a proper initialized bcm_op structure when bcm_proc_show() traverses the bcm_op's under rcu_read_lock().
To cover all initial settings of the bcm_op's the list_add_rcu() calls are moved to the end of the setup code.
While at it, also fix the mirroring removal side: bcm_release() called bcm_remove_op() - which frees the op via call_rcu() - on ops that were still linked in bo->tx_ops/bo->rx_ops, without list_del_rcu() first. Unlink each op with list_del_rcu() before handing it to bcm_remove_op(), matching the existing pattern in bcm_delete_tx_op()/bcm_delete_rx_op().
From the CVE record · Linux
The Linux kernel’s CAN BCM code has missing RCU list operations when adding and removing operations, which can leave operations improperly initialized during traversal or still linked when scheduled for freeing. The input does not specify what an attacker can achieve or whether exploitation requires local or network access, authentication, or user interaction.
Teams running Linux kernels with the affected CAN BCM code should check their kernel versions; affected versions are not specified.