From 096b043a8581ad43f030323a69b4e6c6e78530fa Mon Sep 17 00:00:00 2001 From: Vadim Kochan Date: Tue, 5 May 2015 23:06:56 +0300 Subject: sock: Fix capturing extra packets from other dev Create PF_PACKET socket with proto=0 which does not setup packet handler and will not capture packets until bind() will be invoked. Also replaced pf_tx_socket by pf_socket as these funcs became the same, as proto arg is set to 0. Suggested-by: Daniel Borkmann Signed-off-by: Vadim Kochan Acked-by: Daniel Borkmann Signed-off-by: Tobias Klauser --- sock.h | 1 - 1 file changed, 1 deletion(-) (limited to 'sock.h') diff --git a/sock.h b/sock.h index 0e680ef..50f7102 100644 --- a/sock.h +++ b/sock.h @@ -3,7 +3,6 @@ extern int af_socket(int af); extern int pf_socket(void); -extern int pf_tx_socket(void); extern void set_nonblocking(int fd); extern int set_nonblocking_sloppy(int fd); extern int set_reuseaddr(int fd); -- cgit v1.2.3-54-g00ecf