What's new
  • SNBForums Code of Conduct

    SNBForums is a community for everyone, no matter what their level of experience.

    Please be tolerant and patient of others, especially newcomers. We are all here to share and learn!

    The rules are simple: Be patient, be nice, be helpful or be gone!

URL blocking per device ?

Prasad1337

New Around Here
I noticed the firewall has the ability to block specific URLs but for the entire network. Is there any way I can achieve this for specific devices without using something like DNS filtering or openVPN ?


Thanks and kind regards
Prasad
 
You can try to handcraft some iptables rules like:

Code:
# Block example.com from specified devices
iptables -A FORWARD -i br0 -m mac --mac-source xx:xx:xx:xx:xx:xx -p tcp -d example.com -j DROP # Substitute device1's MAC for the x'es
iptables -A FORWARD -i br0 -m mac --mac-source xx:xx:xx:xx:xx:xx -p tcp -d example.com -j DROP # Substitute device2's MAC for the x'es
in /jffs/scripts/firewall-start

Note that this is not foolproof: if example.com translates to multiple IPs, this rule will not be effective.
 

Similar threads

Support SNBForums w/ Amazon

If you'd like to support SNBForums, just use this link and buy anything on Amazon. Thanks!

Sign Up For SNBForums Daily Digest

Get an update of what's new every day delivered to your mailbox. Sign up here!
Back
Top