Commit Graph
5 Commits
Author SHA1 Message Date
David Wragg 12b969004e Filter outbound packets in the kernel
It turns out that under Linux, libpcap implements the SetDirection
filtering in userspace, causing some spurious wake ups of the packet
capture thread.  So set a BPF filter to discard outbound packets inside
the kernel.
2014-09-17 23:42:48 +01:00
Matthias Radestock 7b85049e0b fix error handling in pcap creation 2014-08-20 17:28:14 +01:00
Matthias Radestock 1a41df1edf zero copy capture
delay copying until necessary
2014-08-20 16:08:43 +01:00
Matthias Radestock 7c4464c852 pcap handles are not thread safe
they contain an errbuf; there might be other issues too.
So we must use different handles in the sniffer and udplistener
goroutines.
2014-08-20 11:42:55 +01:00
Matthias Radestock cb2cdc90cc introduce abstraction for packet i/o 2014-08-20 11:18:12 +01:00