Close ports on Linode Debian
WLS-ITGuy last edited by
I have been trying to figure out what firewall I have on our Debian host but cannot. I did a port scan and found that we have some ports open that I want to close as I know we don't use any of them.
JaredBusch last edited by JaredBusch
apt-get install -y ufw
Then open only what you need to use. Here are examples.
ufw enable ufw allow in ssh ufw allow in http ufw allow in https ufw allow in 10000:20000/udp
JaredBusch last edited by
FYI, this writes to
iptablesfor you as far as I know.
scottalanmiller last edited by
Beyond using a firewall, you can also set whatever ports to simply not be open. Firewalls block ports, but leave them open. You can close them additionally. Your best defense is doing both.
Pete.S last edited by Pete.S
By default Debian comes with iptables. It will allowing everything but a normal Debian install have no services running.
iptables -Lto see the firewall rules.
On Debian 10 the default is nftables.