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: <87ikuzc455.fsf@toke.dk>
Date: Fri, 13 Sep 2024 11:08:22 +0200
From: Toke Høiland-Jørgensen <toke@...hat.com>
To: Breno Leitao <leitao@...ian.org>, kuba@...nel.org, bpf@...r.kernel.org,
 Daniel Borkmann <daniel@...earbox.net>, Nikolay Aleksandrov
 <razor@...ckwall.org>, "David S. Miller" <davem@...emloft.net>, Eric
 Dumazet <edumazet@...gle.com>, Paolo Abeni <pabeni@...hat.com>, Alexei
 Starovoitov <ast@...nel.org>, Jesper Dangaard Brouer <hawk@...nel.org>,
 Sebastian Andrzej Siewior <bigeasy@...utronix.de>
Cc: vadim.fedorenko@...ux.dev, andrii@...nel.org, "open list:BPF [NETKIT]
 (BPF-programmable network device)" <netdev@...r.kernel.org>, open list
 <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH net] netkit: Assign missing bpf_net_context

Breno Leitao <leitao@...ian.org> writes:

> During the introduction of struct bpf_net_context handling for
> XDP-redirect, the netkit driver has been missed, which also requires it
> because NETKIT_REDIRECT invokes skb_do_redirect() which is accessing the
> per-CPU variables. Otherwise we see the following crash:
>
> 	BUG: kernel NULL pointer dereference, address: 0000000000000038
> 	bpf_redirect()
> 	netkit_xmit()
> 	dev_hard_start_xmit()
>
> Set the bpf_net_context before invoking netkit_xmit() program within the
> netkit driver.
>
> Fixes: 401cb7dae813 ("net: Reference bpf_redirect_info via task_struct on PREEMPT_RT.")
> Signed-off-by: Breno Leitao <leitao@...ian.org>
> Acked-by: Daniel Borkmann <daniel@...earbox.net>
> Reviewed-by: Sebastian Andrzej Siewior <bigeasy@...utronix.de>

Reviewed-by: Toke Høiland-Jørgensen <toke@...hat.com>


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ