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: <71bd92d07f21cbca5176e39774463b0ac135ad45.camel@redhat.com>
Date:   Sun, 04 Oct 2020 16:00:44 +0200
From:   Davide Caratti <dcaratti@...hat.com>
To:     Guillaume Nault <gnault@...hat.com>,
        David Miller <davem@...emloft.net>,
        Jakub Kicinski <kuba@...nel.org>
Cc:     netdev@...r.kernel.org, Martin Varghese <martin.varghese@...ia.com>
Subject: Re: [PATCH net] net/core: check length before updating Ethertype
 in skb_mpls_{push,pop}

On Fri, 2020-10-02 at 21:53 +0200, Guillaume Nault wrote:
> Openvswitch allows to drop a packet's Ethernet header, therefore
> skb_mpls_push() and skb_mpls_pop() might be called with ethernet=true
> and mac_len=0. In that case the pointer passed to skb_mod_eth_type()
> doesn't point to an Ethernet header and the new Ethertype is written at
> unexpected locations.
> 
> Fix this by verifying that mac_len is big enough to contain an Ethernet
> header.
> 
> Fixes: fa4e0f8855fc ("net/sched: fix corrupted L2 header with MPLS 'push' and 'pop' actions")
> Signed-off-by: Guillaume Nault <gnault@...hat.com>
> ---
> Notes:
>   - Found by code inspection.
>   - Using commit fa4e0f8855fc for the Fixes tag because mac_len is
>     needed for the test. The problem probably exists since openvswitch
>     can pop the Ethernet header though.
> 
>  net/core/skbuff.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)


Acked-by: Davide Caratti <dcaratti@...hat.com>

thanks!

-- 
davide


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ