Hello,
I am thinking of preventing my wireless printer from accessing the internet but allow assess to my local home network. Can this be done via iptables? I tried the below, but it does not work...
192.168.1.157 is the ip of a computer which I used for testing. After I SSH to the router and issued the above two commands, the computer can still ping site such as google.com...
My next step is to allow some devices to assess the internet only, and via port 80 and 443. These devices cannot assess the local home network.
Any guidance is much appreciated. Thanks!
I am thinking of preventing my wireless printer from accessing the internet but allow assess to my local home network. Can this be done via iptables? I tried the below, but it does not work...
Code:
iptables -A OUTPUT -s 192.168.1.157 -d 192.168.1.1/255.255.255.0 -j ACCEPT
iptables -A OUTPUT -s 192.168.1.157 -j DROP
192.168.1.157 is the ip of a computer which I used for testing. After I SSH to the router and issued the above two commands, the computer can still ping site such as google.com...
My next step is to allow some devices to assess the internet only, and via port 80 and 443. These devices cannot assess the local home network.
Any guidance is much appreciated. Thanks!