反向ip,在ip地址上查找域名

时间:2010-09-01 19:58:43

标签: dns whois

此类http://www.yougetsignal.com/tools/web-sites-on-web-server/这样的网站如何以及从哪里获取此信息?我该如何开发这样的工具?

谢谢。

7 个答案:

答案 0 :(得分:80)

您可以在IP上使用nslookup。反向DNS由.in-addr.arpa域定义。

示例:

nslookup somedomain.com

产生123.21.2.3,然后你做:

nslookup 123.21.2.3

这将询问3.2.21.123.in-addr.arpa并产生域名(如果有反向DNS定义的域名)。

答案 1 :(得分:8)

您可以使用ping -a <ip>nbtstat -A <ip>

答案 2 :(得分:5)

他们只是在浏览网站列表,并将结果IP地址记录在数据库中。

您所看到的只是该列表的反向映射。它不能保证是一个完整的列表(实际上通常不会这样)因为不可能学习每个可能的网站地址。

答案 3 :(得分:1)

来自yougetsignal上的反向IP域检查工具的部分:

  

反向IP域检查需要指向域名或IP地址   到Web服务器并搜索已知托管的其他站点   同一个Web服务器。 从搜索引擎结果中收集数据,   但不保证是完整的。

答案 4 :(得分:1)

windows用户只需使用简单的nslookup命令

即可
G:\wwwRoot\JavaScript Testing>nslookup 208.97.177.124
Server:  phicomm.me
Address:  192.168.2.1

Name:    apache2-argon.william-floyd.dreamhost.com
Address:  208.97.177.124


G:\wwwRoot\JavaScript Testing>

http://www.guidingtech.com/2890/find-ip-address-nslookup-command-windows/

  

如果您想了解更多信息,请查看以下答案!

https://superuser.com/questions/287577/how-to-find-a-domain-based-on-the-ip-address/1177576#1177576

答案 5 :(得分:1)

我是host.io的创建者,它的工作与此类似,它向您显示了托管在同一IP地址上的所有域的列表(以及链接到该域的域的列表,等等) )。例如,以下是与stackoverflow.com使用相同IP托管的域的列表:https://host.io/stackoverflow.com

其他答案告诉您如何将域解析为IP地址,但这只是如何查找IP上托管的所有域的一小部分。为此,您首先需要获取(或创建)所有可用域名的列表。目前大约有2.5亿。下一步是将所有这些域解析为IP地址。然后,您需要将所有这些域到IP对存储在数据库中,然后可以查询以获取同一IP上所有域的列表。然后,您需要定期执行此操作以确保它保持最新状态。

举一个完整的例子,让我们创建一个具有4个域的文件并将其解析为IP地址:

$ cat domains.txt
facebook.com
fb.com
stackoverflow.com
stackexchange.com

# Let's resolve the domains to IPs with dig - could use nslookup or similar
$ cat domains.txt | xargs -I% bash -c "dig +short % | tail -n1" > ips.txt
31.13.76.68
31.13.76.68
151.101.129.69
151.101.193.69

# Let's combine the domains and IPs using paste
$ paste domains.txt ips.txt > combined.tsv
$ cat combined.tsv
facebook.com    31.13.76.68
fb.com  31.13.76.68
stackoverflow.com   151.101.129.69
stackexchange.com   151.101.129.69

# Let's create a DB table and import the data, and write a query 
# to find any domains in our dataset that are hosted on the same 
# domain as stackoverflow.com

$ psql $DB_URL

=> create table details (domain text, ip text);
=> \copy details from ~/combined.tsv;

=> select domain from details where ip = (select ip from details where domain = 'stackoverflow.com');
      domain
-------------------
 stackoverflow.com
 stackexchange.com
(2 rows)

答案 6 :(得分:0)

这对我来说在Intranet中获取域名

https://gist.github.com/jrothmanshore/2656003

这是一个powershell脚本。在PowerShell中运行它

.\ip_lookup.ps1 <ip>
相关问题