Nmap Development mailing list archives
Re: [PATCH] Re: WARNING: Unable to find appropriate interface for system route to ...
From: clozapina <clozapina () gmail com>
Date: Fri, 5 May 2006 00:18:30 +0200
Hi kx, i applied your patch in 4.02Alpha2 with this result: nmap-4.02Alpha2 root# ./nmap -sS -p 80 xx.xx.xx.xx -P0 -e ppp0 Starting Nmap 4.02Alpha2 ( http://www.insecure.org/nmap/ ) at 2006-05-05 00:07 CEST Interesting ports on host.bla.bla (xx.xx.xx.xx): PORT STATE SERVICE 80/tcp open http Nmap finished: 1 IP address (1 host up) scanned in 4.746 seconds It seems work fine. Good job. Today i try to use 4.03. This the the result: nmap-4.03 root# ./nmap -sS -p 80 xx.xx.xx.xx -P0 -e ppp0 Starting Nmap 4.03 ( http://www.insecure.org/nmap/ ) at 2006-05-05 00:09 CEST WARNING: Unable to find appropriate interface for system route to 217.201.xx.xx WARNING: Unable to find appropriate interface for system route to 217.201.xx.xx WARNING: Unable to find appropriate interface for system route to 217.201.xx.xx WARNING: Unable to find appropriate interface for system route to 217.201.xx.xx WARNING: Unable to find appropriate interface for system route to 217.201.xx.xx WARNING: Unable to find appropriate interface for system route to 217.201.xx.xx WARNING: Unable to find appropriate interface for system route to 217.201.xx.xx WARNING: Unable to find appropriate interface for system route to 217.201.xx.xx WARNING: Unable to find appropriate interface for system route to 217.201.xx.xx Interesting ports on host.bla.bla (xx.xx.xx.xx): PORT STATE SERVICE 80/tcp open http Nmap finished: 1 IP address (1 host up) scanned in 5.239 seconds I search your patch in tcpip.cc, but nothing. Why ? thks On 22 Apr 2006, at 06:52, kx wrote:
Until someone can point me to a place where they think something else is broken, this will fix the warning. I forced a failure and ran a test and the patch worked. Test output below. NOTE: There is no need to always override the routing table, as route_dst() will override the interface when actually sending: memcpy(&rnfo->ii, iface, sizeof(rnfo->ii)); This patch just saves us from throwing a route away that dnet knows about, but we can't match to an interface. Cheers, kx --- tcpip.cc 2006-03-25 17:56:16.000000000 -0500 +++ tcpip.cc.new 2006-04-22 00:41:21.875000000 -0400 @@ -2180,6 +2180,19 @@ } } if (i == dcrn->numifaces) { + /* We didn't find a matching device and we are about to fail to load this + route into the table. However, if the user specified an interface, let it + override failing here. */ + if (*o.device) { + dcrn->routes[dcrn->numroutes].device = getInterfaceByName (o.device); + if (!dcrn->routes[dcrn->numroutes].device) { + error("Could not find interface %s which was specified by -e", o.device); + } + else { + dcrn->numroutes++; + return 0; + } + } error("WARNING: Unable to find appropriate interface for system route to %s\n", addr_ntoa(&entry->route_gw)); return 0; }nmap -p80,81 scanme.insecure.org -OStarting Nmap 4.02CSW ( http://www.insecure.org/nmap ) at 2006-04-22 00:35 Eastern Daylight Time WARNING: Unable to find appropriate interface for system route to 192.168.1.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 192.168.1.100 WARNING: Unable to find appropriate interface for system route to 127.0.0.1 WARNING: Unable to find appropriate interface for system route to 192.168.1.100 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 WARNING: Unable to find appropriate interface for system route to 192.168.1.100 WARNING: Unable to find appropriate interface for system route to 192.168.1.100 nexthost: failed to determine route to 205.217.153.62 QUITTING!nmap -p80,81 scanme.insecure.org -O -e eth0Starting Nmap 4.02CSW ( http://www.insecure.org/nmap ) at 2006-04-22 00:35 Eastern Daylight Time Warning: OS detection will be MUCH less reliable because we did not find at lea st 1 open and 1 closed TCP port Interesting ports on scanme.nmap.org.48.153.217.205.in-addr.arpa (205.217.153.62): PORT STATE SERVICE 80/tcp open http 81/tcp filtered hosts2-ns Device type: broadband router Running: Linksys embedded OS details: Linksys WAG54G Wireless Gateway Uptime 0.162 days (since Fri Apr 21 20:42:19 2006) Nmap finished: 1 IP address (1 host up) scanned in 7.797 seconds On 4/21/06, kx <kxmail () gmail com> wrote:Well, that looks like valid output. I know how to get rid of that warning when -e is specified and will submit a proposal patch soon. No idea why the OpenBSD had the sendto() error, sorry Damian. Cheers, kx <tcpip.cc.patch.txt>
_______________________________________________ Sent through the nmap-dev mailing list http://cgi.insecure.org/mailman/listinfo/nmap-dev
Current thread:
- WARNING: Unable to find appropriate interface for system route to ... gianluigi angotti (Apr 17)
- Re: WARNING: Unable to find appropriate interface for system route to ... kx (Apr 18)
- Re: WARNING: Unable to find appropriate interface for system route to ... clozapina (Apr 18)
- Re: WARNING: Unable to find appropriate interface for system route to ... kx (Apr 18)
- Re: WARNING: Unable to find appropriate interface for system route to ... clozapina (Apr 19)
- Re: WARNING: Unable to find appropriate interface for system route to ... kx (Apr 20)
- Re: WARNING: Unable to find appropriate interface for system route to ... clozapina (Apr 21)
- Re: WARNING: Unable to find appropriate interface for system route to ... kx (Apr 21)
- [PATCH] Re: WARNING: Unable to find appropriate interface for system route to ... kx (Apr 21)
- Re: [PATCH] Re: WARNING: Unable to find appropriate interface for system route to ... clozapina (May 04)
- Re: [PATCH] Re: WARNING: Unable to find appropriate interface for system route to ... kx (May 04)
- Re: [PATCH] Re: WARNING: Unable to find appropriate interface for system route to ... Fyodor (May 28)
- Re: [PATCH] Re: WARNING: Unable to find appropriate interface for system route to ... kx (May 28)
- Re: WARNING: Unable to find appropriate interface for system route to ... clozapina (Apr 18)
- Re: WARNING: Unable to find appropriate interface for system route to ... kx (Apr 18)