bpf: Do not dereference user pointer in bpf_test_finish().
authorDavid Miller <davem@davemloft.net>
Tue, 2 May 2017 15:36:33 +0000 (11:36 -0400)
committerDavid S. Miller <davem@davemloft.net>
Tue, 2 May 2017 15:46:28 +0000 (11:46 -0400)
commit78e5227237cae9172dd50c3ebb08d4fb31530676
treedee17546a9954815c29301898074534defeb3b79
parent4e9c3a667135799d50f2778a8a8dae2ca13aafd0
bpf: Do not dereference user pointer in bpf_test_finish().

Instead, pass the kattr in which has a kernel side copy of this
data structure from userspace already.

Fix based upon a suggestion from Alexei Starovoitov.

Signed-off-by: David S. Miller <davem@davemloft.net>
Acked-by: Daniel Borkmann <daniel@iogearbox.net>
net/bpf/test_run.c