#ifndef BPF_I_H #define BPF_I_H #include #include #include #include "xmalloc.h" #include "bpf_insns.h" #include "bpf_ext.h" #include "config.h" extern void bpf_dump_op_table(void); extern void bpf_dump_all(struct sock_fprog *bpf); extern int __bpf_validate(const struct sock_fprog *bpf); extern uint32_t bpf_run_filter(const struct sock_fprog *bpf, uint8_t *packet, size_t plen); extern void bpf_attach_to_sock(int sock, struct sock_fprog *bpf); extern void bpf_detach_from_sock(int sock); extern int enable_kernel_bpf_jit_compiler(void); extern void bpf_parse_rules(char *rulefile, struct sock_fprog *bpf, uint32_t link_type); #if defined(HAVE_TCPDUMP_LIKE_FILTER) && defined(NEED_TCPDUMP_LIKE_FILTER) extern void bpf_try_compile(const char *rulefile, struct sock_fprog *bpf, uint32_t link_type); #else static inline void bpf_try_compile(const char *rulefile, struct sock_fprog *bpf __maybe_unused, uint32_t link_type __maybe_unused) { panic("Cannot open file %s!\n", rulefile); } #endif static inline void bpf_release(struct sock_fprog *bpf) { free(bpf->filter); } #endif /* BPF_I_H */ move' selected='selected'>nds-private-remove net-next plumbingsTobias Klauser
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKees Cook <keescook@chromium.org>2016-06-23 15:06:53 -0700
committerKees Cook <keescook@chromium.org>2016-07-26 14:41:49 -0700
commitdfd45b6103c973bfcea2341d89e36faf947dbc33 (patch)
tree7f9a7a3069064efc667a8845ca0a263a8c620315
parent5b710f34e194c6b7710f69fdb5d798fdf35b98c1 (diff)
ARM: uaccess: Enable hardened usercopy
Enables CONFIG_HARDENED_USERCOPY checks on arm. Based on code from PaX and grsecurity. Signed-off-by: Kees Cook <keescook@chromium.org>