Nmap Development mailing list archives

Re: Adding libdnet and libpcap to nbase (was: Status Report #5 of #15)


From: Fyodor <fyodor () insecure org>
Date: Thu, 10 Jun 2010 18:53:40 -0700

On Tue, Jun 08, 2010 at 09:21:41AM +0200, Luis MartinGarcia. wrote:

* Make it possible for nbase to use libdnet and libpcap.
* Try to move the rest of the code shared between Nmap and Nping
  to Nbase.

While I can see how you would need to do that in order to share common
tcpip code between nping and nmap, I'm a little bit skeptical of this
idea.  I think of Nbase as a base library for portability stuff and
core utility functions.  For example, it provides functions like
getopt_long, inet_pton, inet_ntop, and snprintf for systems which
don't offer them.  And it has some core utility functions for string
processing, memory allocation, random number generation, etc.  For the
random numbers, we pulled in OpenSSL code but didn't add a requirement
for the OpenSSL library.

I worry that making nbase dependent on libdnet and libpcap will not
only cloud its (admittedly already murky) focus, but also cause
near-term practical problems.  For example, Ithilgore recently spent
several days making libpcap removable from Nsock so it could still be
used in Ncrack.  Ncrack also uses Nbase, so we could run into the same
issue if we now go and add libpcap to that.

Maybe it would make more sense to create a new Nmap
tcpip/networking/packet/internals library (I'm not sure what all you
have in mind) for this rather than stuffing everything into Nbase?

Cheers,
Fyodor
_______________________________________________
Sent through the nmap-dev mailing list
http://cgi.insecure.org/mailman/listinfo/nmap-dev
Archived at http://seclists.org/nmap-dev/


Current thread: