Home page logo

nmap-dev logo Nmap Development mailing list archives

Re: nmap sending encapsulated packets
From: Kris Katterjohn <katterjohn () gmail com>
Date: Wed, 02 Apr 2008 18:51:28 -0500

Hash: SHA1

Mike Lude wrote:
Now with almost any scan I do (for example, 
nmap -T Aggressive -O -v 
it says that it can't find the host, and when I add the suggested -PN 
parameter it lists all ports as filtered, even though I have a 
perfectly accessible webserver running on the host to be scanned.

So, I break out wireshark to see what's going on, and trace what nmap 
is sending and what I am receiving at the host. Every single outgoing 
packet is encapsulated, with a protocol of 0xFF. Here's a hex dump of 
the first packet sent:

0000  9c f4 20 00 03 00 03 00  03 00 00 00 08 00 45 00   
0010  00 3c 94 91 00 00 80 ff  ed 8c c0 a8 9b 3d c0 a8   
0020  9b 16 45 00 00 28 71 62  00 00 2c 06 65 c9 c0 a8   
0030  9b 3d c0 a8 9b 16 d3 0d  00 50 79 f3 1a 0a 00 00   
0040  42 ba 50 10 04 00 4a 1a  00 00                     

This matches exactly with what I see on the host being scanned.

Hmm.. I don't know; hopefully somebody else on this list can say
something definitive.

Here's what I'd try:

1) Obviously, make sure any firewalls and other network trickery are
turned off.

2a) Run Nmap with as few options as possible (no timing options, no OS
detection, etc).  You probably want to narrow down the port ranges (-p)
though, for ease of examination.

2b) While running, use Nmap's --packet-trace option and Wireshark to
watch the packets.  See what Nmap says it's sending and see what
Wireshark actually reads.  --packet-trace won't give you a full packet
dump, but using it should tell you what Nmap thinks it's doing.

This explains the "filtered" messages (the scanned host dropped all 
of the packets on the floor due to unrecognized protocol) but I've 
clearly got something very screwed up. What am I doing wrong?

Not just an unrecognized protocol, but if I'm not mistaken protocol 0xFF
should never actually be sent over a network.  I think the old hack
(1980's) for sending raw IP packets w/headers involved patching the
kernel and setting the socket() protocol field to 0xFF since it should
never be used for anything.

Again, I'm on WinXP SP2 with all of the latest fixes.

/Mike Ludé

Kris Katterjohn

Version: GnuPG v1.4.6 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org


Sent through the nmap-dev mailing list
Archived at http://SecLists.Org

  By Date           By Thread  

Current thread:
[ Nmap | Sec Tools | Mailing Lists | Site News | About/Contact | Advertising | Privacy ]