hide:
smartdns is a DNS server that is bound to port 53 by default. Running smartdns in root permissions may lead to external data queries. Therefore, we can improve the security of smartdns as follows:
Specify a non-root user to run, such as running as nobody
user nobody
Specify the IP address or NIC to bind to via the bind parameter
Bind to a specific IP
bind 192.168.1.1:53
Bind to a specific NIC
bind [::]:53@eth0
Provide services to outside world through a TLS server
bind-tls [::]:853@eth0
SmartDNS can enable audit logging to record DNS query requests with the following configuration:
audit-enable yes
audit-num 16
audit-size 16M
audit-file /var/log/smartdns/smartdns-audit.log