lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <6dc06795-9bfd-9bde-cab7-66dae0920b14@hartkopp.net>
Date:   Tue, 8 Jun 2021 20:56:57 +0200
From:   Oliver Hartkopp <socketcan@...tkopp.net>
To:     Kirill Tkhai <ktkhai@...tuozzo.com>,
        Tetsuo Handa <penguin-kernel@...ove.sakura.ne.jp>
Cc:     "David S. Miller" <davem@...emloft.net>,
        Jakub Kicinski <kuba@...nel.org>, netdev@...r.kernel.org,
        Marc Kleine-Budde <mkl@...gutronix.de>,
        linux-can@...r.kernel.org
Subject: Re: [PATCH v2] can: bcm/raw/isotp: use per module netdevice notifier



On 07.06.21 18:15, Kirill Tkhai wrote:
> On 05.06.2021 13:26, Tetsuo Handa wrote:

>>
>> Updated patch is shown below.
>>
>>
>>  From 12c61ae3d06889c9bbc414f0230c05dc630f6409 Mon Sep 17 00:00:00 2001
>> From: Tetsuo Handa <penguin-kernel@...ove.SAKURA.ne.jp>
>> Date: Sat, 5 Jun 2021 19:18:21 +0900
>> Subject: [PATCH v2] can: bcm/raw/isotp: use per module netdevice notifier
>>
>> syzbot is reporting hung task at register_netdevice_notifier() [1] and
>> unregister_netdevice_notifier() [2], for cleanup_net() might perform
>> time consuming operations while CAN driver's raw/bcm/isotp modules are
>> calling {register,unregister}_netdevice_notifier() on each socket.
>>
>> Change raw/bcm/isotp modules to call register_netdevice_notifier() from
>> module's __init function and call unregister_netdevice_notifier() from
>> module's __exit function, as with gw/j1939 modules are doing.
>>
>> Link: https://syzkaller.appspot.com/bug?id=391b9498827788b3cc6830226d4ff5be87107c30 [1]
>> Link: https://syzkaller.appspot.com/bug?id=1724d278c83ca6e6df100a2e320c10d991cf2bce [2]
>> Reported-by: syzbot <syzbot+355f8edb2ff45d5f95fa@...kaller.appspotmail.com>
>> Reported-by: syzbot <syzbot+0f1827363a305f74996f@...kaller.appspotmail.com>
>> Tested-by: syzbot <syzbot+355f8edb2ff45d5f95fa@...kaller.appspotmail.com>
>> Signed-off-by: Tetsuo Handa <penguin-kernel@...ove.SAKURA.ne.jp>
> 
> Reviewed-by: Kirill Tkhai <ktkhai@...tuozzo.com>

Tested-by: Oliver Hartkopp <socketcan@...tkopp.net>

Hello Tetsuo and Kirill,

thanks for your effort and the review!

Indeed I really had problems to get behind the locking but now I got it 
(hopefully) :-)

At least I can confirm that the original functionality still works for 
all three affected CAN protocols (bcm/isotp/raw).

Many thanks and best regards,
Oliver

> 
>> ---
>>   net/can/bcm.c   | 59 +++++++++++++++++++++++++++++++++++-----------
>>   net/can/isotp.c | 61 +++++++++++++++++++++++++++++++++++++-----------
>>   net/can/raw.c   | 62 ++++++++++++++++++++++++++++++++++++++-----------
>>   3 files changed, 142 insertions(+), 40 deletions(-)
>>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ