Results 1 to 2 of 2
Thread: Linux Firewall/Proxy/ ???
Enjoy an ad free experience by logging in. Not a member yet? Register.
- Join Date
- Apr 2012
Linux Firewall/Proxy/ ???
So to begin, we are going to have a LAN party (just with some friends) on doomsday (21 december). So the plan is, that i install a Server (wich i have) between the modem and the router. (Yes the server has 2 network ports)
Now i want to block all internet connection from a certain time. I just don't know how to do it.
You could read up on what rules do and how to use them with this TUTORIAL
Here is a very simple setup that will allow all connections out and only established connection back in.
iptables -P INPUT DROP iptables -P OUTPUT DROP iptables -P FORWARD DROP iptables -A INPUT -i <inside> -m conntrack --ctstate NEW,RELATED,ESTABLISHED-j ACCEPT iptables -A OUTPUT -o <inside> -m conntrack --ctstate NEW,RELATED,ESTABLISHED-j ACCEPT iptables -A FORWARD -i <inside> -m conntrack --ctstate NEW,RELATED,ESTABLISHED-j ACCEPT iptables -A FORWARD -i <outside> -m conntrack --ctstate RELATED,ESTABLISHED-j ACCEPT
What the above does is allow you to log into the server from the LAN only.
Traffic will pass from the LAN to the WAN and only established connection will be allowed to pass from the WAN to the LAN
The adventure of a life time.
Linux User #296285