yesterday i got a rootkit
Sorry to hear that. I hope that you did a complete wipe, format, and re-installation from trusted media.
i want to secure my linux file server.
Good. Doing it correctly the first time will save you the hastle of rebuilding it again.
So my question is how can i tell redhat 9 - i want 2 open ports on this machine it´´s 22 ssh and 2223 for my console
Use the following general format to open up ports:
iptables -I INPUT -p tcp -dport XXX - j ACCEPT
where XXX is the port you want to open. Though I would recommend limiting access only those IPs which you need to allow connections from (if that is at all feasible). If you don' t mind me asking. what are you planing using port 2223 for?