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-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <90db4107-18a3-6324-1425-b7c24c399154@omp.ru>
Date:   Thu, 27 Jan 2022 12:37:21 +0300
From:   Sergey Shtylyov <s.shtylyov@....ru>
To:     Damien Le Moal <damien.lemoal@...nsource.wdc.com>,
        Zhou Qingyang <zhou1615@....edu>
CC:     <kjlu@....edu>, Alexander Shiyan <shc_work@...l.ru>,
        "Bartlomiej Zolnierkiewicz" <b.zolnierkie@...sung.com>,
        Jens Axboe <axboe@...nel.dk>, <linux-ide@...r.kernel.org>,
        <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] ata: pata_platform: Fix a NULL pointer dereference in
 __pata_platform_probe()

Hello!

On 1/27/22 5:15 AM, Damien Le Moal wrote:

>>> In __pata_platform_probe(), devm_kzalloc() is assigned to ap->ops and
>>> there is a dereference of it right after that, which could introduce a
>>> NULL pointer dereference bug.
>>>
>>> Fix this by adding a NULL check of ap->ops.
>>>
>>> This bug was found by a static analyzer.
>>>
>>> Builds with 'make allyesconfig' show no new warnings,
>>> and our static analyzer no longer warns about this code.
>>>
>>> Fixes: f3d5e4f18dba ("ata: pata_of_platform: Allow to use 16-bit wide data transfer")
>>> Signed-off-by: Zhou Qingyang <zhou1615@....edu>
>>
>> Reviewed-by: Sergey Shtylyov <s.shtylyov@....ru>
> 
> Please see my note about the typo in the fix. I kept you RB tag. Let me

   Oops, didn't expect such a stupid bug, so my brain did add the missing ! prolly... :-)
Not clear how he managed to shut up his static analyzer with this patch...

> know if that is OK.

   Of course, sorry for the messy review! :-)

>> [...]

MBR, Sergey

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ