Toggle navigation
Koozali.org: home of the SME Server
Community
Forums
Bugs
Lists
Forum Help
Download
SME Server ISOs
Contribs
Documentation
Manual
Wiki
FAQ
HowTo
Donate
Search
Login
Register
Login
Register
×
Close
Login
Remember me
Koozali.org: home of the SME Server
Legacy Forums
Experienced User Forum
Topic:
iptables block ports
« previous
next »
+
Print
Pages: [
1
]
Go Down
iptables block ports
2 Replies
1692 Views
wasserja
iptables block ports
«
on:
March 16, 2004, 11:50:10 PM »
I am running SME 5.6. I want to know how to block all ports, then enable just the basics like 80, 443, 21, etc.
How can I make a custom iptables rule to accomplish this feat?
wasserja
Logged
Lars Kjeldsen
Try this.
«
Reply #1 on:
March 17, 2004, 12:36:23 AM »
Hi
Go to this path and open the masq
/etc/init.d/masq
Find this string:
# Adjust all inbound TCP connection rules
And add this string efter the line above.
adjust_tcp_in
23
denylog InboundTCP_$$
Do that with all ports you want to close.
after that enter this command in the shell:
service masq restart
Regards Lars Kjeldsen
Logged
wasserja
iptables block ports
«
Reply #2 on:
March 17, 2004, 01:07:12 AM »
What if I want to block all ports, then allow 80, 443, etc?
Logged
+
Print
Pages: [
1
]
Go Up
« previous
next »
Koozali.org: home of the SME Server
Legacy Forums
Experienced User Forum
Topic:
iptables block ports