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: <c0596a62-0873-5638-920b-235c55ff33a2@linux.dev>
Date:   Wed, 5 Apr 2023 12:38:48 -0700
From:   Martin KaFai Lau <martin.lau@...ux.dev>
To:     Magnus Karlsson <magnus.karlsson@...il.com>,
        Kal Conley <kal.conley@...tris.com>
Cc:     Björn Töpel <bjorn@...nel.org>,
        Magnus Karlsson <magnus.karlsson@...el.com>,
        Maciej Fijalkowski <maciej.fijalkowski@...el.com>,
        Jonathan Lemon <jonathan.lemon@...il.com>,
        "David S. Miller" <davem@...emloft.net>,
        Eric Dumazet <edumazet@...gle.com>,
        Jakub Kicinski <kuba@...nel.org>,
        Paolo Abeni <pabeni@...hat.com>,
        Alexei Starovoitov <ast@...nel.org>,
        Daniel Borkmann <daniel@...earbox.net>,
        Jesper Dangaard Brouer <hawk@...nel.org>,
        John Fastabend <john.fastabend@...il.com>,
        Maxim Mikityanskiy <maximmi@...lanox.com>,
        netdev@...r.kernel.org, bpf@...r.kernel.org,
        linux-kernel@...r.kernel.org
Subject: Re: [PATCH bpf] xsk: Fix unaligned descriptor validation

On 4/3/23 11:25 PM, Magnus Karlsson wrote:
> On Mon, 3 Apr 2023 at 16:38, Kal Conley <kal.conley@...tris.com> wrote:
>>
>> Make sure unaligned descriptors that straddle the end of the UMEM are
>> considered invalid. Currently, descriptor validation is broken for
>> zero-copy mode which only checks descriptors at page granularity.
>> Descriptors that cross the end of the UMEM but not a page boundary may
>> be therefore incorrectly considered valid. The check needs to happen
>> before the page boundary and contiguity checks in
>> xp_desc_crosses_non_contig_pg. Do this check in
>> xp_unaligned_validate_desc instead like xp_check_unaligned already does.
> 
> Thanks for catching this Kal.
> 
> Acked-by: Magnus Karlsson <magnus.karlsson@...el.com>

Is this case covered by an existing test?

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ