Mirror of strace – the linux syscall tracer
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

bpf_filter.h 685B

123456789101112131415161718192021222324252627282930
  1. /*
  2. * Classic BPF filter block.
  3. *
  4. * Copyright (c) 2015-2018 Dmitry V. Levin <ldv@altlinux.org>
  5. * All rights reserved.
  6. *
  7. * SPDX-License-Identifier: LGPL-2.1-or-later
  8. */
  9. #ifndef STRACE_BPF_FILTER_H
  10. # define STRACE_BPF_FILTER_H
  11. struct bpf_filter_block {
  12. uint16_t code;
  13. uint8_t jt;
  14. uint8_t jf;
  15. uint32_t k;
  16. };
  17. typedef bool (*print_bpf_filter_fn)(const struct bpf_filter_block *);
  18. extern void
  19. print_bpf_fprog(struct tcb *const tcp, const kernel_ulong_t addr,
  20. const unsigned short len, const print_bpf_filter_fn print_k);
  21. extern void
  22. decode_bpf_fprog(struct tcb *const tcp, const kernel_ulong_t addr,
  23. const print_bpf_filter_fn print_k);
  24. #endif /* !STRACE_BPF_FILTER_H */