我正在服务器中配置安全性。为了简化防火墙管理,我安装了UFW。我在UFW中进行了一些设置,并允许了一些端口。因此,当我启用它时,DNS服务没有响应。
我尝试运行命令DIG www.domain.com.br
来测试DNS,但未成功。禁用UFW时,此命令运行不会出现问题。我已经允许使用53端口(TCP和UDP),但是DNS无法正常工作。
我的UFW设置:
Status: active
Logging: on (low)
Default: deny (incoming), deny (outgoing), disabled (routed)
New profiles: skip
To Action From
-- ------ ----
21/tcp ALLOW IN Anywhere
16/tcp ALLOW IN Anywhere
443/tcp ALLOW IN Anywhere
80 ALLOW IN Anywhere
53 ALLOW IN Anywhere
465 ALLOW IN Anywhere
25/tcp ALLOW IN Anywhere
22 ALLOW IN Anywhere
21/tcp (v6) ALLOW IN Anywhere (v6)
16/tcp (v6) ALLOW IN Anywhere (v6)
443/tcp (v6) ALLOW IN Anywhere (v6)
80 (v6) ALLOW IN Anywhere (v6)
53 (v6) ALLOW IN Anywhere (v6)
465 (v6) ALLOW IN Anywhere (v6)
25/tcp (v6) ALLOW IN Anywhere (v6)
22 (v6) ALLOW IN Anywhere (v6)
我尝试过,但是没有用。
—
diegoklapper 2014年
ufw status verbose
...