Nmap Development mailing list archives

Re: nmap errors on *BSDs (noted on NetBSD and MacOSX, so far)


From: David Fifield <david () bamsoftware com>
Date: Tue, 23 Mar 2010 12:01:35 -0600

On Tue, Mar 23, 2010 at 06:55:30PM +0100, Fredrik Pettai wrote:
On Mar 23, 2010, at 5:57 PM, David Fifield wrote:
On Tue, Mar 23, 2010 at 05:28:29PM +0100, Fredrik Pettai wrote:
I've noted two problems that has surfaced in between the release of  
nmap
5.00 (2009-07-15) -> 5.10BETA1 (2009-11-23).


The other, more problematic error (not present on Mac OS X AFAIK), is
then you run nmap as root on NetBSD, you get this error:

# ./nmap -A ping.sunet.se

Starting Nmap 5.10BETA1 ( http://nmap.org ) at 2010-03-23 16:35 CET
WARNING: Unable to find appropriate interface for system route to
193.10.5.1
WARNING: Unable to find appropriate interface for system route to
127.0.0.1
WARNING: Unable to find appropriate interface for system route to
127.0.0.1
Target* nexthost(HostGroupState*, TargetGroup*, scan_lists*, int):
failed to determine route to ping.sunet.se (192.36.125.18)
QUITTING!

However, running as a normal user, it works as expected.

This is probably not an error related to NetBSD, but to the routing
table on this particular host. Please send in the output of
"nmap --iflist". Some bugs related to routing were fixed recently and
aren't yet in an official release, and this might be affecting you.

I compiled nmap from pkgsrc on the same Mac, and then I get the same  
errors as on NetBSD.
(Could it be due to that pkgsrc relies on libpcap and pcre from the  
pkgsrc tree.)

nmap-5.21 ->
libpcap-1.0.0nb2    System-independent interface for user-level packet  
capture
pcre-8.00           Perl Compatible Regular Expressions library

I also compiled the SVN version (in pkgsrc on NetBSD), and it fails the 
same way as before:

bash-4.0# ./work/nmap-5.22/nmap --iflist

Starting Nmap 5.21 ( http://nmap.org ) at 2010-03-23 18:52 CET
INTERFACES: NONE FOUND(!)
WARNING: Unable to find appropriate interface for system route to  
193.10.5.1
WARNING: Unable to find appropriate interface for system route to  
127.0.0.1
WARNING: Unable to find appropriate interface for system route to  
127.0.0.1
ROUTES: NONE FOUND(!)

"INTERFACES: NONE FOUND(!)" is definitely the error here. That's not
expected. Give me some time to think more about what might be causing
it. The first thing I can think of offhand is to check the permissions
on the /dev/bpf devices.

$ ls -l /dev/bpf*

Also send the output of "netstat -rn". That will be the routing table as
it's supposed to be. You only need to send the "Internet" part, not the
"Internet6" part.

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


Current thread: