CodyKochmann
10/15/2015 - 10:38 PM

This is the first command I run on a new ubuntu machine in order to set up a simple firewall allowing only exclusively what I want.

This is the first command I run on a new ubuntu machine in order to set up a simple firewall allowing only exclusively what I want.

for i in outgoing incoming
do
  ufw default deny $i
done
for i in ssh http https "out http" "out https" 1194/udp 53
do
  ufw allow $i
done
&& ufw enable