[erlang-questions] packet sniffing

Angel clist@REDACTED
Wed Feb 3 22:19:49 CET 2010


On Martes, 26 de Enero de 2010 14:52:00 Joe Armstrong escribió:
> Can I use the standard socket libraries to sniff all packets from an
>  interface?
> 
> I have a C driver that does
> 
>           rawsock = socket(PF_PACKET, SOCK_RAW, htons(p ETH_P_IP))
> 
> and then binds rawsock to "eth0"
> 
> Can I do the equivalent directly in Erlang and throw away my C code?
> 
> Also can I bind a listening socket to an arbitrary interface?
> 
> 
> /Joe
> 
Hi i came across this page:

http://xumingyong.javaeye.com/blog/585229

He is using erl_nif 

Now he is doing a new sniffer on XP....


/Angel



More information about the erlang-questions mailing list