OPENWRT implementation of wireless internet whitelist

Source: Internet
Author: User

Internet filtering is done by modifying the firewall configuration file.

Configuration file/etc/config/firewall

1. White List of Macs

At the end of the configuration file, add the following:

Config rule
Option src LAN
Option Dest WAN
Option Src_mac 9c:d2:1e:f9:34:39
Option Target ACCEPT

Config rule
Option src LAN
Option Dest WAN
Option Src_mac 98:6C:F5:5B:11:BC
Option Target ACCEPT

Config rule
Option src LAN
Option Dest WAN
Option Target REJECT

The above rules are interpreted as: Allow two devices with MAC address 9c:d2:1e:f9:34:39, 98:6C:F5:5B:11:BC to surf the internet, other devices refuse to go to the outside network

Attention:

Config rule
Option src LAN
Option Dest WAN
Option Target REJECT

Deny all devices to the outside of the network of this rule to be put behind, firewall rules seem to have priority

After the configuration file has been modified successfully, restart the firewall

#/etc/init.d/firewall Restart

2. IP Whitelist

Principle Step Ibid.

Simply place the rule in the

Option Src_mac MAC address

Switch

Option SRC_IP The IP address you want to allow

Copyright NOTICE: This article for Bo Master original article, without Bo Master permission not reproduced.

OpenWrt to implement wireless internet whitelist

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.