erlang packet sniffer scanner
Javier París Fernández
Fri Apr 28 19:09:54 CEST 2006
El Viernes, 28 de Abril de 2006 18:41, a escribió:
> I would like to use erlang in a school assignment writing a packet
> sniffer I am new to this langauge
> but what I have read it appears to scale better than java
> threads ... and with the ip support it appears
> to take less code than java.... Any direction or guidance would be
Mmm, writing a packet sniffer has two challenges:
- Capturing all the packets: Ok, you cannot really use only Erlang for this.
You will have to write a C Port that either uses a raw socket (this is in
linux), or for better portability, uses the libpcap library (I don't know if
your school will consider this cheating). To be fair, I don't think this can
be done natively in Java either.
- Analyzing the packets you are receiving. For this Erlang bit syntax will
make your life easy. This part will probably be much easier in Erlang than
However, I don't understand why you want a large number of threads for this.
I think that one thread doing the capture work and another one making the
analysis should be enough... (Maybe I'm wrong on this)
More information about the erlang-questions