Project of BUPT IoT 2022 junior summer school.
- Supports all DNS request types
- Caching mechanism
- Multi-threaded concurrent handling of requests
- Customizable blacklist
- Support IPv6 address
- DNS load balancing
- Auto cache cleaning
- Blacklist expiry time
- Server logs
- User configuration
- Customizable remote DNS server address
- Enable/disable caching mechanism
- Customizable thread pool size
- Customizable cache validity period
Java 15 or higher
Customize your settings in boot.properties.
Add websites to cache.txt as follows:
blacklist [website you want to block]. 0.0.0.0
blacklist [website you want to block].-v6 ::
If you want to set expiry time, here's an example:
2022/07/02 www.taobao.com. 0.0.0.0
2022/07/02 www.taobao.com.-v6 ::
Assume the cache limit is set to 2 days. Then the server will block www.taobao.com until 2022/07/04.
Run the application and check if the server started successfully on the terminal.
Then create a new terminal window and execute:
nslookup www.bupt.edu.cn 127.0.0.1
The server should return both IPv4 and IPv6 addresses(ipv6 protocol enabled).
Now you can set your local DNS server as 127.0.0.1(ipv4) and ::1(ipv6).
If something wrong happens, you can check it in log.txt.
- Wang Zaitian @ZaitianWang
- Zhang Zeyu @JerryZhangZZY