Re: [PATCH net] can: af_can: fix NULL pointer dereference in can_rx_register()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 28.10.2022 13:24:36, Oliver Hartkopp wrote:
> Didn't have remembered that specific discussion.
> 
> Wouldn't we need this check in can_rx_unregister() and maybe

The kernel should not call can_rx_unregister() if can_rx_register()
fails, but on the other hand we check for ARPHRD_CAN here, too.

> can[|fd|xl]_rcv() then too?
> 
> As all these functions check for ARPHRD_CAN and later access ml_priv.

Better safe then sorry.

Marc

-- 
Pengutronix e.K.                 | Marc Kleine-Budde           |
Embedded Linux                   | https://www.pengutronix.de  |
Vertretung West/Dortmund         | Phone: +49-231-2826-924     |
Amtsgericht Hildesheim, HRA 2686 | Fax:   +49-5121-206917-5555 |

Attachment: signature.asc
Description: PGP signature


[Index of Archives]     [Automotive Discussions]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [eCos]     [Asterisk Internet PBX]     [Linux API]     [CAN Bus]

  Powered by Linux