是否可以找到给定域名的所有 DNS 子域?

发布于 2024-07-08 12:34:38 字数 1477 浏览 4 评论 0原文

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(5

乱了心跳 2024-07-15 12:34:38

正如其他人所说,您想要的是所谓的区域转移。 如果它是您自己的域,您可以配置 DNS 服务器以将其提供给您。 如果它用于其他域,您可能无法理解它,因为大多数 DNS 管理员认为它是安全威胁。

即使单个记录不是问题(这就是 DNS 的问题),如果邪恶的人获得了您所有记录的列表,也可能会成为问题:它可以简化攻击。

Like others have said, what you want is a so called zone-transfer. If it is your own domain you can configure the DNS server to give it to you. If it is for some other domain you probably don't get it, since most DNS-admins consider it a security threat.

Even if an individual record isn't a problem (thats what the DNS it therefore) it could be a problem if an evil person gets a list of all your records: It could simplify an attack.

不念旧人 2024-07-15 12:34:38

使用区域传输,即:
(在nslookup中)

ls -d google.com

如果您有自己的DNS服务器,则会有区域传输安全设置(通常通过IP)。 否则,只需尝试一下,看看是否有效。

Using zone transfer, i.e.:
(in nslookup)

ls -d google.com

If you have your own DNS server, there will be zone transfer security settings (usually by IP). Otherwise, just try it and see if it works.

盗琴音 2024-07-15 12:34:38

防止区域传输是服务器管理的一项功能,正如其他人所说,现在出于安全原因通常被禁用。

当需要添加 DNSSEC 时,请确保使用新的 NSEC3 格式记录(来自 RFC 5155)而不是原始的 NSEC 格式,因为后者允许区域枚举。

请注意,防止区域枚举实际上只是通过模糊来实现安全。 如果有人找到您的子域,您仍然需要应用程序层的额外安全性。

至于您的示例记录:

www IN CNAME domain.com.
subdomain1 IN CNAME domain.com.
subdomain2 IN CNAME domain.com. 
subdomain1 IN A 123.4.56.78.
subdomain2 IN A 123.4.56.79.
  1. 您不能在同一实体中混合 CNAME 记录和其他 RRtypes
  2. A 记录中的尾随点无效
  3. 最好不要使用 CNAME 返回 WWW 记录的域

您需要:(

$ORIGIN domain.com
@      IN SOA ...
       IN A   123.4.56.78
www    IN A   123.4.56.78
sub1   IN A   123.4.56.79

其中 < code>sub1.domain.com 是隐藏站点)

Preventing zone-transfers is a function of the server administration, and as others have said is typically disabled these days for security reasons.

When the time comes to add DNSSEC, make sure you use the new NSEC3 format records (from RFC 5155) rather than the original NSEC format as the latter allows for zone enumeration.

Note that preventing zone enumeration really is just security-via-obscurity. If someone finds your subdomain you'll still need additional security at the application layer.

As for your example records:

www IN CNAME domain.com.
subdomain1 IN CNAME domain.com.
subdomain2 IN CNAME domain.com. 
subdomain1 IN A 123.4.56.78.
subdomain2 IN A 123.4.56.79.
  1. You can't mix CNAME records and other RRtypes in the same entity
  2. The trailing dots in the A records are invalid
  3. It's best not to use a CNAME back to the domain for the WWW record

You need:

$ORIGIN domain.com
@      IN SOA ...
       IN A   123.4.56.78
www    IN A   123.4.56.78
sub1   IN A   123.4.56.79

(where sub1.domain.com is the hidden site)

梦归所梦 2024-07-15 12:34:38

过去可以通过以下方式实现:

host -a -l domain.com

It used to be possible with:

host -a -l domain.com
π浅易 2024-07-15 12:34:38

如果名称服务器允许区域传输,您可以使用此页面 http://www.magic-net .info/dns-lookup.dnslookup 查找给定区域中的所有子域。

10 月 15 日 我已经修改了我的工具。 现在,它会检查前 6 个名称服务器的区域传输,如果没有人允许区域传输,则使用搜索引擎 反向查找和子域搜索

If name servers allow zone transfers you can use this page http://www.magic-net.info/dns-lookup.dnslookup to find all subdomains in given zone.

15 oct. I`m have modified my tool. Now it checks first 6 name servers for zone transfers and, if no one allow zone transfers, uses search engeines Reverse lookup and subdomains search

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文