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: <5502046F.4030409@plumgrid.com>
Date:	Thu, 12 Mar 2015 14:26:07 -0700
From:	Alexei Starovoitov <ast@...mgrid.com>
To:	Daniel Borkmann <daniel@...earbox.net>, davem@...emloft.net
CC:	netdev@...r.kernel.org
Subject: Re: [PATCH net-next] cls_bpf: do eBPF invocation under non-bh RCU
 lock variant for maps

On 3/12/15 12:03 PM, Daniel Borkmann wrote:
> Currently, it is possible in cls_bpf to access eBPF maps only under
> rcu_read_lock_bh() variants: while on ingress side, that is, handle_ing(),
> the classifier would be called from __netif_receive_skb_core() under
> rcu_read_lock(); on egress side, however, it's rcu_read_lock_bh() via
> __dev_queue_xmit().
>
> This rcu/rcu_bh mix doesn't work together with eBPF maps as they require
> soley to be called under rcu_read_lock(). eBPF maps could also be shared
> among various other eBPF programs (possibly even with other eBPF program
> types, f.e. tracing) and user space processes, so any context is assumed.
>
> Therefore, a possible fix for cls_bpf is to wrap/nest eBPF program
> invocation under non-bh RCU lock variant.
>
> Fixes: e2e9b6541dd4 ("cls_bpf: add initial eBPF support for programmable classifiers")
> Signed-off-by: Daniel Borkmann <daniel@...earbox.net>

Acked-by: Alexei Starovoitov <ast@...mgrid.com>

thanks!

--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ