]> git.baikalelectronics.ru Git - kernel.git/commit
libbpf: fix detection of corrupted BPF instructions section
authorAndrii Nakryiko <andriin@fb.com>
Wed, 29 May 2019 17:36:03 +0000 (10:36 -0700)
committerDaniel Borkmann <daniel@iogearbox.net>
Wed, 29 May 2019 23:23:34 +0000 (01:23 +0200)
commit32b7454a53476873cc2f30ca7dcb0cb4f1060593
tree4a5d05ae4f807e0a9ac4a9ab5599f57e2adac9ff
parent9714b9e4dcb927437377ca7adf12784180de2a67
libbpf: fix detection of corrupted BPF instructions section

Ensure that size of a section w/ BPF instruction is exactly a multiple
of BPF instruction size.

Signed-off-by: Andrii Nakryiko <andriin@fb.com>
Acked-by: Song Liu <songliubraving@fb.com>
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
tools/lib/bpf/libbpf.c