Hi,
I need to test one specific port on a serie of Ip addresses that I own, I thought about using nmap or telnet, but both return the same value, no matter if the port is open or filtered.
Anyone has an idea, before I start scripting to analyse the output of the command?
Regards,
Ugo
Use nmap. Here I'm scanning my home network for any port 80 that's open
nmap -p 80 192.168.1.0/24
Matt Shields Cyberbite Network - www.cyberbite.com
On 12/7/06, Ugo Bellavance ugob@camo-route.com wrote:
Hi,
I need to test one specific port on a serie of Ip addresses that I own, I thought about using nmap or telnet, but both return the same value, no matter if the port is open or filtered.
Anyone has an idea, before I start scripting to analyse the output of the command?
Regards,
Ugo
CentOS mailing list CentOS@centos.org http://lists.centos.org/mailman/listinfo/centos
It kinda looks like he is looking to use return values to do his scripting....
If so, try netcat.
nc -z -w3 192.168.1.1 80
That will return 0 on open port. 1 on close port. 1 on filtered port. Waits 3 seconds for a response. Wrap in a loop as needed...
Mike
-----Original Message----- From: centos-bounces@centos.org [mailto:centos-bounces@centos.org] On Behalf Of Matt Shields Sent: December 7, 2006 1:55 PM To: CentOS mailing list Subject: Re: [CentOS] Scripting port scans
Use nmap. Here I'm scanning my home network for any port 80 that's open
nmap -p 80 192.168.1.0/24
Matt Shields Cyberbite Network - www.cyberbite.com
On 12/7/06, Ugo Bellavance ugob@camo-route.com wrote:
Hi,
I need to test one specific port on a serie of Ip addresses that I own, I thought about using nmap or telnet, but both return the same value, no matter if the port is open or filtered.
Anyone has an idea, before I start scripting to analyse the output of the command?
Regards,
Ugo
CentOS mailing list CentOS@centos.org http://lists.centos.org/mailman/listinfo/centos
_______________________________________________ CentOS mailing list CentOS@centos.org http://lists.centos.org/mailman/listinfo/centos
mike.redan@bell.ca wrote:
It kinda looks like he is looking to use return values to do his scripting....
If so, try netcat.
nc -z -w3 192.168.1.1 80
That will return 0 on open port. 1 on close port. 1 on filtered port. Waits 3 seconds for a response. Wrap in a loop as needed...
Yes! You rock :).
Ugo
Mike
-----Original Message----- From: centos-bounces@centos.org [mailto:centos-bounces@centos.org] On Behalf Of Matt Shields Sent: December 7, 2006 1:55 PM To: CentOS mailing list Subject: Re: [CentOS] Scripting port scans
Use nmap. Here I'm scanning my home network for any port 80 that's open
nmap -p 80 192.168.1.0/24
Matt Shields Cyberbite Network - www.cyberbite.com
On 12/7/06, Ugo Bellavance ugob@camo-route.com wrote:
Hi,
I need to test one specific port on a serie of Ip addresses that I own, I thought about using nmap or telnet, but both return the same value, no matter if the port is open or filtered.
Anyone has an idea, before I start scripting to analyse the output of the command?
Regards,
Ugo
CentOS mailing list CentOS@centos.org http://lists.centos.org/mailman/listinfo/centos
CentOS mailing list CentOS@centos.org http://lists.centos.org/mailman/listinfo/centos
On Thursday 07 December 2006 10:39, Ugo Bellavance wrote:
Hi,
I need to test one specific port on a serie of Ip addresses that I own, I thought about using nmap or telnet, but both return the same value, no matter if the port is open or filtered.
Anyone has an idea, before I start scripting to analyse the output of the command?
If you're using nagios for any monitoring, there's a nmap plugin in the contrib directory of the nagios-plugins package. It will notify you if the host displays any open ports not pre-defined as open for that host.
On Thu, Dec 07, 2006 at 11:06:01AM -0800, Kevan Benson wrote:
On Thursday 07 December 2006 10:39, Ugo Bellavance wrote:
Hi,
I need to test one specific port on a serie of Ip addresses that I own, I thought about using nmap or telnet, but both return the same value, no matter if the port is open or filtered.
Anyone has an idea, before I start scripting to analyse the output of the command?
If you're using nagios for any monitoring, there's a nmap plugin in the contrib directory of the nagios-plugins package. It will notify you if the host displays any open ports not pre-defined as open for that host.
And there's a check_tcp plugin for the simpler single-port case. You can also use the plugins directly even if you're not using nagios. The nagios-plugins package is available from Dag's rpmforge repo.
Cheers, Gavin