0

What would be the downsides of turning off iptables permanently on a development environment? I don't like the fact that every time I restart virtual box I must do:

service iptables stop
service iptables save

I am sure it might help to leave it on or alter is on production, but does it really matter on development?

1 Answer 1

0

disabling iptables service is easy:

systemctl disable iptables.service

The question is why do you want to disable the firewall. Maybe you just want to open bunch of ports for your application servers and leave the firewall on...

Update: This is basic /etc/sysconfig/iptables configuration allowing incoming requests on port 22 (ssh):

:INPUT ACCEPT [0:0]
:FORWARD ACCEPT [0:0]
:OUTPUT ACCEPT [0:0]
-A INPUT -m state --state ESTABLISHED,RELATED -j ACCEPT
-A INPUT -p icmp -j ACCEPT
-A INPUT -i lo -j ACCEPT
-A INPUT -m state --state NEW -m tcp -p tcp --dport 22 -j ACCEPT
-A INPUT -j REJECT --reject-with icmp-host-prohibited
-A FORWARD -j REJECT --reject-with icmp-host-prohibited
COMMIT
3
  • Well, lets say I am accessing my host at ip 192.168.1.1 then how do I open a port explicitly for this host?
    – Bimlik
    Apr 2, 2014 at 14:50
  • q1: 192.168.1.1 is address of your workstation or address of your server? q2: which port do you want to open?
    – andrej
    Apr 2, 2014 at 15:19
  • I don't know much about vps, but the ip is my address with which I can see my project on my dev server. Port is 22 according to putty that is
    – Bimlik
    Apr 2, 2014 at 15:21

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .