Nmap Development mailing list archives

Re: doubt regarding nsock


From: majek04 <majek04+nmap-dev () gmail com>
Date: Wed, 18 Mar 2009 22:09:47 +0000

On Tue, Mar 17, 2009 at 12:16, venkat sanaka <venkatsanaka () gmail com> wrote:
Hiii everyone..
   i am new to the nmap developing though i have been using it since
quite long bac.
I had been studying the code of nmap for last 3-4 days and after doing
this i was wondering
why nscok doesnt deal with raw sockets while most of the nmap code
uses raw sockets except for sum code where nsock is used???can someone
plzz answer my question and let me know if i was wrong in interpreting
the usage of nsock and why it is used for??

Nsock has raw sockets support.
If you ask why Nmap doesn't use Nsock raw sockets, here
the answer is complicated.

Mainly, because of historical reasons. Pcap support
for Nsock is pretty new, and relatively untested.

Making Pcap working on Nsock was not easy, and it's
still possible that there are some corner cases where
pcap@nsock would not behave as expected.

Also, on some platforms, pcap@nsock code can delay
incoming packet up to 50ms, which is not the perfect
situation.

But in general, I'd say that nmap internal code
could benefit if it used nsock pcap instead of
internal pcap functions. I believe that, at least some,
parts of nmap could be much easier to read and clearer.

Though, some people on the list may not share my point of view.
Fyodor?

Marek Majkowski

_______________________________________________
Sent through the nmap-dev mailing list
http://cgi.insecure.org/mailman/listinfo/nmap-dev
Archived at http://SecLists.Org

Current thread: