Re: [PATCH bpf] bpf: fix replace_map_fd_with_map_ptr's ldimm64 second imm field

2019-03-07 Thread Alexei Starovoitov
On Mon, Mar 04, 2019 at 09:08:53PM +0100, Daniel Borkmann wrote: > Non-zero imm value in the second part of the ldimm64 instruction for > BPF_PSEUDO_MAP_FD is invalid, and thus must be rejected. The map fd > only ever sits in the first instructions' imm field. None of the BPF > loaders known to us

Re: [PATCH bpf] bpf: fix replace_map_fd_with_map_ptr's ldimm64 second imm field

2019-03-04 Thread Song Liu
On Mon, Mar 4, 2019 at 12:09 PM Daniel Borkmann wrote: > > Non-zero imm value in the second part of the ldimm64 instruction for > BPF_PSEUDO_MAP_FD is invalid, and thus must be rejected. The map fd > only ever sits in the first instructions' imm field. None of the BPF > loaders known to us are usi

[PATCH bpf] bpf: fix replace_map_fd_with_map_ptr's ldimm64 second imm field

2019-03-04 Thread Daniel Borkmann
Non-zero imm value in the second part of the ldimm64 instruction for BPF_PSEUDO_MAP_FD is invalid, and thus must be rejected. The map fd only ever sits in the first instructions' imm field. None of the BPF loaders known to us are using it, so risk of regression is minimal. For clarity and consisten