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>] [day] [month] [year] [list]
Date:   Mon, 31 Aug 2020 06:26:50 +0000
From:   linmiaohe <linmiaohe@...wei.com>
To:     Jens Axboe <axboe@...nel.dk>
CC:     "linux-block@...r.kernel.org" <linux-block@...r.kernel.org>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] block: bio: Trim bio to sensible size in bio_trim()

Jens Axboe <axboe@...nel.dk> wrote:
>On 8/29/20 3:37 AM, Miaohe Lin wrote:
>> Trim bio to sensible size in bio_trim() or something bad may happen.
>
>This really needs a LOT more detail. What is "something bad"? How does this condition trigger to begin with?
>

Many thanks for your reply.

I do this mainly by code review, so I didn't find the condition trigger to begin with. But I think it's better
to do such a check as this is a external Interface. Also If bio_trim() set bio->bi_iter.bi_size to a value larger than the origin one,
we may access the bio_vec past the last one of bio->bi_io_vec in for_each_bvec macro.

>--
>Jens Axboe
>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ