config: add some config guide

This commit is contained in:
Nick Peng
2023-03-10 23:53:17 +08:00
parent dcb680ae88
commit 39efbda313
14 changed files with 507 additions and 184 deletions

40
docs/config/security.md Normal file
View File

@@ -0,0 +1,40 @@
---
hide:
- toc
---
# 安全相关
smartdns为DNS服务器默认绑定53端口这时smartdns需要root权限并且有可能导致外网也能进行数据查询。所以通过如下方式对smartdns进行安全加固
## 使用非root权限运行
通过user指定非root用户运行如使用nobody运行
```shell
user nobody
```
## 绑定特定的IP或网口
通过bind参数指定绑定的IP地址或网口
1. 绑定特定的IP
```shell
bind 192.168.1.1:53
```
1. 绑定特定的网口
```shell
bind [::]:53@eth0
```
## 对公网提供查询时使用TLS服务器
使用TLS服务器对外提供服务
```shell
bind-tls [::]:853@eth0
```