3
1
I wish to set up a secure home file server on a Debian computer. I will be using my own server software that utilizes only a single TCP port. To make sure that the machine is fully secure, I'm thinking that I should close all ports except for the one my protocol is running on (such that no other protocol can be used or accessed on the machine).
Does anyone know what the best way is to close all of the ports except for one?
I forgot to add, you can save these rules by running
iptables-save > /path/to/file/you/want
. You can then append the line/sbin/iptables-restore < /path/to/file/you/saved
to/etc/rc.local
so that these rules are loaded on boot. – ChrisR. – 2014-05-14T22:04:27.990Don't forget you have to manage IPV6 as well. You can probably Drop all packets or copy the same as above using ip6tables. – Spencer5051 – 2014-05-14T22:44:20.670