I'm trying to set up a bastion network with lan access to internet. This is my diagram.
I have internet acces in the linux firewall (I'm using a lubuntu 16.04). And I can ping from lubuntuclon (192.168.10.2) to the firewall (192.168.10.1) perfectly. So I think is working. The problem is that I cannot acces internet from the LAN. I think it's a matter of iptables but It's not working as expected. This are the iptables rules I'm using:
Flush the rules:
iptables -F
iptables -X
iptables -Z
iptables -t nat -F
Politics:
iptables -P INPUT ACCEPT
iptables -P OUTPUT ACCEPT
iptables -P FORWARD ACCEPT
iptables -t nat -P PREROUTING ACCEPT
iptables -t nat -P POSTROUTING ACCEPT
Rules:
iptables -A INPUT -i lo -j ACCEPT
iptables -A INPUT -s 192.168.10.0/24 -i enp0s8 -j ACCEPT -->so the LAN has access to the firewall
iptables -t nat -A POSTROUTING -s 192.168.10.0/24 -o enp0s3 -j MASQUERADE --> so the lan has internet access
but when I ping 8.8.8.8 from lubunutuclon or winxpclon I got no response. I cannot acces internet from browser neither, of course.
I think my rules are wrong. But I cannot figure why. Any help?