Nmap Security Scanner
*Intro
*Ref Guide
*Install Guide
*Download
*Changelog
*Book
*Docs
Security Lists
*Nmap Hackers
*Nmap Dev
*Bugtraq
*Full Disclosure
*Pen Test
*Basics
*More
Security Tools
*Pass crackers
*Sniffers
*Vuln Scanners
*Web scanners
*Wireless
*Exploitation
*Packet crafters
*More
Site News
Site Search:
Exploit World
Advertising
About/Contact
Credits
Sponsors:
edgeos



Nmap Development: Re: [PATCH] OpenBSD ioctl() performance improvement

Re: [PATCH] OpenBSD ioctl() performance improvement

From: Kris Katterjohn <katterjohn_at_gmail.com>
Date: Sat, 24 Feb 2007 16:25:19 -0600

doug_at_hcsw.org wrote:
> I am attaching my current patch to nmap-4.21ALPHA1 but I don't think it's ready for incorporation yet. Here is what remains to be done:
>
> * Figure out what other operating systems will benefit from BIOCIMMEDIATE (I suspect at least NetBSD).
>
> * Find a better way than the #define hack in my patch. The BIOCIMMEDIATE constant is straight out of OpenBSD's /usr/include/net/bpf.h . Ideally we should #include <net/bpf.h> as described in OpenBSD's man bpf. I tried this but some of the structures defined there conflict with the bpf.h that nmap currently includes.
>
> If anybody has any ideas or suggestions regarding the above points please reply to nmap-dev!
>

Which bpf.h are you talking about Nmap including? pcap-bpf.h? Including
net/bpf.h somewhere before the pcap.h #include in tcpip.h should work if
that's the case.

From pcap-bpf.h (which gets included from pcap.h):

--snip--

/*
 * This is libpcap's cut-down version of bpf.h; it includes only
 * the stuff needed for the code generator and the userland BPF
 * interpreter, and the libpcap APIs for setting filters, etc..
 *
 * "pcap-bpf.c" will include the native OS version, as it deals with
 * the OS's BPF implementation.
 *
 * XXX - should this all just be moved to "pcap.h"?
 */

#ifndef BPF_MAJOR_VERSION

--snip--

Since net/bpf.h should (definitely) #define BPF_MAJOR_VERSION then the
conflicting stuff in this header won't be included and all should work
(since pcap-bpf.h is just a "cut-down version")

I certainly hope pcap-bpf.h was the one you were talking about or that
was for nothing :)

> Best,
>
> Doug
>

I'm in the process of moving and just got online some today and I might
be on a little tomorrow, so any replies might be delayed.

Thanks,
Kris Katterjohn

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

Received on Feb 24 2007
[ Nmap | Sec Tools | Mailing Lists | Site News | About/Contact | Advertising | Privacy ]