[PATCH bpf v3 0/3] bpf: Fix null-pointer-deref in resolve_prog_type()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



v3: 
 - Add a small selftest for the BPF CI, and split 1-patch into
   3-patch series as recommended by Daniel.
   https://lore.kernel.org/all/d16b4f29-8966-464f-b530-35e39fda3f46@xxxxxxxxxxxxxxx/

v2: 
 - Fix libbpf_probe_prog_types test failure reported by CI by
   adapting libbpf code. (thanks for jirka's reminder)

v1: https://lore.kernel.org/all/20240620060701.1465291-1-wutengda@xxxxxxxxxxxxxxx/

Hi,

This series is going to fix null-pointer-deref in resolve_prog_type()
for BPF_PROG_TYPE_EXT.
Patch 1 is the kernel-only fix, patch 2 is the libbpf one, and patch 3
is a small BPF selftest.

Best regards,
Tengda

Tengda Wu (3):
  bpf: Fix null pointer dereference in resolve_prog_type() for
    BPF_PROG_TYPE_EXT
  libbpf: provide a valid attach_prog_fd before probing
    BPF_PROG_TYPE_EXT type
  selftests/bpf: Test for null-pointer-deref bugfix in
    resolve_prog_type()

 kernel/bpf/syscall.c                         |  5 ++++-
 tools/lib/bpf/libbpf_probes.c                | 13 ++++++++++++-
 tools/testing/selftests/bpf/verifier/calls.c | 13 +++++++++++++
 3 files changed, 29 insertions(+), 2 deletions(-)

-- 
2.34.1





[Index of Archives]     [Linux Samsung SoC]     [Linux Rockchip SoC]     [Linux Actions SoC]     [Linux for Synopsys ARC Processors]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]


  Powered by Linux