setDirestion() in Windows.
nonokatori opened this issue · comments
nonokatori commented
Hi!
I am writing a sniffer.
I need to choose the direction of the packets being caught (source or destination), but the method setDirection(PcapHandle.PcapDirection dir)
does not work under Windows.
Is there any way to solve this problem? Or is made this method only for Linux?
Ardika Rommy Sanjaya commented
From the docs:
- https://www.tcpdump.org/manpages/pcap_setdirection.3pcap.html
- https://nmap.org/npcap/guide/wpcap/pcap_setdirection.html
pcap_setdirection() isn't necessarily fully supported on all platforms;
some platforms might return an error for all values, and some other platforms might not support PCAP_D_OUT.
nonokatori commented
Thank you! You helped me a lot!
I thought I was doing something wrong.