Re: [RFC net-next PATCH 2/2] bpf: disallow XDP data_meta to overlap with xdp_frame area

2018-04-18 Thread Daniel Borkmann
On 04/18/2018 07:53 PM, Jesper Dangaard Brouer wrote: > On Wed, 18 Apr 2018 18:21:21 +0200 > Daniel Borkmann wrote: > >> On 04/18/2018 02:10 PM, Jesper Dangaard Brouer wrote: >>> If combining xdp_adjust_head and xdp_adjust_meta, then it is possible >>> to make data_meta

Re: [RFC net-next PATCH 2/2] bpf: disallow XDP data_meta to overlap with xdp_frame area

2018-04-18 Thread Jesper Dangaard Brouer
On Wed, 18 Apr 2018 18:21:21 +0200 Daniel Borkmann wrote: > On 04/18/2018 02:10 PM, Jesper Dangaard Brouer wrote: > > If combining xdp_adjust_head and xdp_adjust_meta, then it is possible > > to make data_meta overlap with area used by xdp_frame. And another > > invocation

Re: [RFC net-next PATCH 2/2] bpf: disallow XDP data_meta to overlap with xdp_frame area

2018-04-18 Thread Daniel Borkmann
On 04/18/2018 02:10 PM, Jesper Dangaard Brouer wrote: > If combining xdp_adjust_head and xdp_adjust_meta, then it is possible > to make data_meta overlap with area used by xdp_frame. And another > invocation of xdp_adjust_head can then clear that area, due to > clearing of xdp_frame area. > >

[RFC net-next PATCH 2/2] bpf: disallow XDP data_meta to overlap with xdp_frame area

2018-04-18 Thread Jesper Dangaard Brouer
If combining xdp_adjust_head and xdp_adjust_meta, then it is possible to make data_meta overlap with area used by xdp_frame. And another invocation of xdp_adjust_head can then clear that area, due to clearing of xdp_frame area. The easiest solution I found was to simply not allow