View previous topic :: View next topic |
Author |
Message |
Kindred n00b

Joined: 27 Feb 2004 Posts: 9
|
Posted: Fri Aug 20, 2004 9:15 pm Post subject: command to list open ports? |
|
|
The old admin left so I don't know what some server applications are using for ports, so what is the command to see? |
|
Back to top |
|
 |
ElForesto n00b


Joined: 26 Feb 2004 Posts: 26 Location: Salt Lake City, UT USA
|
Posted: Fri Aug 20, 2004 9:20 pm Post subject: |
|
|
This will list things being listened for:
If that doesn't give you what you want, check the man page. [/code] |
|
Back to top |
|
 |
hensan l33t


Joined: 26 Jun 2003 Posts: 868 Location: Sweden
|
Posted: Fri Aug 20, 2004 9:25 pm Post subject: |
|
|
You can also try nmap. |
|
Back to top |
|
 |
beandog Bodhisattva


Joined: 04 May 2003 Posts: 2072 Location: /usa/utah
|
Posted: Fri Aug 20, 2004 9:27 pm Post subject: |
|
|
hensan wrote: | You can also try nmap. |
Yahp. nmap localhost _________________ If it ain't broke, tweak it. dvds | blurays | blog | wiki |
|
Back to top |
|
 |
kashani Advocate


Joined: 02 Sep 2002 Posts: 2032 Location: San Francisco
|
Posted: Fri Aug 20, 2004 11:18 pm Post subject: |
|
|
netstat -ptln is a bit more readable IMO.
kashani _________________ Will personally fix your server in exchange for motorcycle related shop tools in good shape. |
|
Back to top |
|
 |
krolden Apprentice


Joined: 28 May 2004 Posts: 293 Location: Belgium
|
Posted: Fri Aug 20, 2004 11:44 pm Post subject: |
|
|
sdibb wrote: | hensan wrote: | You can also try nmap. |
Yahp. nmap localhost |
Won't that give incorrect results?
If your IPtables are configured that all packets from lo interface are to be accepted, you will see all your packets get through.
Besides, I don't think nmap can handle localhost, at least the older versions couldn't scan when giving 127.0.0.1 as target IP.
Anyways, check this out. It might prove convenient.
http://www.linuxsecurity.com/docs/LDP/Security-Quickstart-HOWTO/appendix.html#NETSTAT |
|
Back to top |
|
 |
beandog Bodhisattva


Joined: 04 May 2003 Posts: 2072 Location: /usa/utah
|
Posted: Sat Aug 21, 2004 3:45 am Post subject: |
|
|
Krolden wrote: | sdibb wrote: | hensan wrote: | You can also try nmap. |
Yahp. nmap localhost |
Won't that give incorrect results?
If your IPtables are configured that all packets from lo interface are to be accepted, you will see all your packets get through.
Besides, I don't think nmap can handle localhost, at least the older versions couldn't scan when giving 127.0.0.1 as target IP.
Anyways, check this out. It might prove convenient.
http://www.linuxsecurity.com/docs/LDP/Security-Quickstart-HOWTO/appendix.html#NETSTAT |
Yes, you're right -- if you run it locally, it will display all the ports that are open that you locally can connect to, but not from the outside in. Still its a quick and dirty indication if you just want to know what's running. _________________ If it ain't broke, tweak it. dvds | blurays | blog | wiki |
|
Back to top |
|
 |
|