LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 07-09-2009, 07:27 PM   #1
genmaicha
Member
 
Registered: Apr 2009
Posts: 38

Rep: Reputation: 15
nmap ping scan- custom ports?


I want to do host discovery (and no scanning at all) using nmap's -sP option. Now, the nmap reference manual says:
Quote:
The -sP option sends an ICMP echo request, TCP SYN to port 443, TCP ACK to port 80, and an ICMP timestamp request by default.
In otherwords, it 'knocks' on some ports in case it can't get an echo reply. However, when I try to run nmap ping sweep on a custom port (say telnet), I get:

Code:
nmap -sP -p 25 192.168.100.2-254

Starting Nmap 4.76 ( http://nmap.org ) at 2009-07-09 17:32 PDT
You cannot use -F (fast scan) or -p (explicit port selection) with PING scan or LIST scan
QUITTING!
Am I missing something here? Since -sP sends tcp packets, shouldn't it be possible to customize which ports to use?
 
Old 07-10-2009, 01:19 AM   #2
anomie
Senior Member
 
Registered: Nov 2004
Location: Texas
Distribution: RHEL, Scientific Linux, Debian, Fedora
Posts: 3,935
Blog Entries: 5

Rep: Reputation: Disabled
Quote:
Originally Posted by genmaicha
Am I missing something here? Since -sP sends tcp packets, shouldn't it be possible to customize which ports to use?
I have an older nmap version (4.11) and it's also not possible there. So the answer to your second question would seem to be: "no".

If you really want to do host discovery (icmp echo and tcp SYN to port 80) + customize the tcp SYN scan, then just use e.g.:
Code:
$ nmap host.here -p 22,80,443,3389
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
tcpwrapped? from nmap scan. deepsix Linux - Security 5 10-05-2010 05:55 PM
LXer: Learn how to use nmap, and nmap GUI, a great port scan tool LXer Syndicated Linux News 0 01-03-2008 09:10 AM
nmap scan sucram2g Linux - Security 2 03-18-2006 02:21 AM
Fedora Core 3, GRC port scan says ports arestealthed but responds to icmp ping IraB Linux - Security 7 12-09-2004 11:18 PM
nmap scan loganwva Linux - Security 5 02-25-2003 07:16 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 06:44 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration