Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
All Ports Blocked?
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
nickc
n00b
n00b


Joined: 22 Jun 2003
Posts: 30
Location: UK

PostPosted: Sat Jun 28, 2003 10:31 am    Post subject: All Ports Blocked? Reply with quote

Just installed Gentoo recently and every port seems to be blocked by default:

nmap -sX 127.0.0.1

Starting nmap 3.27 ( www.insecure.org/nmap/ ) at 2003-06-28 12:31 GMT
All 1623 scanned ports on localhost (127.0.0.1) are: closed

Nmap run completed -- 1 IP address (1 host up) scanned in 1.701 seconds

Strange thing is, when I run iptables -L it doesn't initilise properly:

iptables -L
modprobe: Can't locate module ip_tables
iptables v1.2.8: can't initialize iptables table `filter': iptables who? (do you need to insmod?)
Perhaps iptables or your kernel needs to be upgraded.

All I really wan to know is how I can open some common ports like ssh and vnc?

Thanks
Back to top
View user's profile Send private message
tphamm
Tux's lil' helper
Tux's lil' helper


Joined: 01 Jun 2003
Posts: 112
Location: Saskatoon, SK, CA

PostPosted: Sat Jun 28, 2003 2:33 pm    Post subject: Reply with quote

Hi nickc,

You need to have daemons listening on those ports before they will be open. Eg. sshd will open port 22, xinetd will listen on whatever ports it is configured for... You can start these using the scripts in /etc/init.d

netstat -natu will also show you what ports are open on your local computer.
_________________
"This is a UNIX system! I know this!" -- little girl from dinasaur park
Back to top
View user's profile Send private message
slartibartfasz
Veteran
Veteran


Joined: 29 Oct 2002
Posts: 1462
Location: Vienna, Austria

PostPosted: Sat Jun 28, 2003 9:04 pm    Post subject: Reply with quote

the whole thing works somewhat like this:

() there is a convention that every service has a certain port number (like most ip numbers also have a name)

() when u want to connect to another computer u knock at its door and ask for the program foo with the portnumber 99 (or ssh with port 22)

() if the computer u are trying to connect to has the correct daemon running - when someone is at home - the door will open

() if no one is at home u simply get no response - the port is closed

if u want to open a port, all u have to do, is to start a program that listens for someone who is knocking and then answers - thats what tphamm already explained...
_________________
To an engineer the glass is neither half full, nor half empty - it is just twice as big as it needs to be.
Back to top
View user's profile Send private message
nickc
n00b
n00b


Joined: 22 Jun 2003
Posts: 30
Location: UK

PostPosted: Sat Jul 26, 2003 10:32 am    Post subject: Reply with quote

Thanks for the help. I still have a problem though, I have started a VNC server and verified that the ports are open and it's listening.

When I try to VNC into it I get refused, I've checked the VNC server logs and it tells me that the server is up but nothing about a refused connection. This suggests that somehting (Not the VNC server though) is dropping the connection...

Any ideas what's doing this?

Thanks, Nick
Back to top
View user's profile Send private message
devon
l33t
l33t


Joined: 23 Jun 2003
Posts: 943

PostPosted: Sat Jul 26, 2003 6:46 pm    Post subject: Reply with quote

Does /var/log/secure show anything? Do you have iptables running?
Back to top
View user's profile Send private message
nickc
n00b
n00b


Joined: 22 Jun 2003
Posts: 30
Location: UK

PostPosted: Sat Jul 26, 2003 8:16 pm    Post subject: Reply with quote

devon wrote:
Does /var/log/secure show anything? Do you have iptables running?


Thanks, I don't have iptbles running and I have no such file on my system... What else could this be?
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum