Nmap Development mailing list archives
Re[2]: nmap vs multiple IP address on one NIC
From: preacherandrew () mail ru
Date: Wed, 31 Oct 2007 09:41:27 +0300
On Tue, Oct 23, 2007, Fyodor wrote:
On Fri, Oct 19, 2007 at 04:36:45PM +0400, preacherandrew () mail ru wrote:Hi, Fyodor. My config: Windows 2000; one NIC; in TCP/IP properties set multiple IP addresses
Hi Andrew. Thanks for your report. Maybe we need to move tne entry->>intf_len assignment. Would you please email your report to nmap-dev () insecure org so that more people have a chance to look at it?
Thanks, -F
Hi Fyodor. I have send my report to nmap-dev () insecure org. But may be problem is wider. I try to fix the problem moving memset(entry, 0, sizeof(*entry)); from "_ifrow_to_entry" function and code fragment "set aliases" is executed. But this fix don't help me in my case ("multiple IP addresses on one network card"). Point is that nmap use only one from addresses returned by GetIpAddrTable. Becase that nmap's rerults may be inadequate. For example: host has two IP adresses on one network card - 192.168.160.12/24 and 192.168.2.3/24. Default router - 192.168.160.254. 1) I run "nmap --iflist". 2) GetIpAddrTable returns addresses is such order: 192.168.2.3, 192.168.160.12. 2) Nmap take into account only first address returned by GetIpAddrTable- 192.168.2.3. 3) Then nmap try verify default router using this address (192.168.2.3). This results "WARNING: Unable to find appropriate interface for system route to 192.168.160.254" (more precisely lot such warnings - for almost each entry in "route print"). In reality, default router is ok - it is reachable from host's other address (192.168.160.12), but nmap doesn't take into account other address. IMHO this is design problem (at least in Windows version of nmap). Several IP on one NIC is not problem for standard ping utility. But this is the problem for nmap. Andrew.
nmap prints out: "WARNING: Unable to find appropriate interface for system route to ..." I've downloaded sources of nmap and did some debugging. In source intf-win32.c: 427: entry->intf_len = sizeof(ebuf); 428: _ifrow_to_entry(intf, &intf->iftable->table[i], entry); and then inside function "_ifrow_to_entry": memset(entry, 0, sizeof(*entry)); In result field "entry->intf_len" is 0. Code fragment "set aliases" (strings 153-158 in "intf-win32.c") threrefore cannot execute. Andrew. mailto:preacherandrew () mail ru P.S. sorry for my English.
-- С уважением, preacherandrew mailto:preacherandrew () mail ru _______________________________________________ Sent through the nmap-dev mailing list http://cgi.insecure.org/mailman/listinfo/nmap-dev Archived at http://SecLists.Org
Current thread:
- Re[2]: nmap vs multiple IP address on one NIC preacherandrew (Oct 30)
- Re: nmap vs multiple IP address on one NIC David Fifield (Nov 19)
- Message not available
- Re: nmap vs multiple IP address on one NIC 'David Fifield' (Nov 20)
- Re: nmap vs multiple IP address on one NIC 'David Fifield' (Nov 26)
- Message not available
- Re: nmap vs multiple IP address on one NIC David Fifield (Nov 19)