云提供商IP地址解析

问题描述

是否可以确定IP地址是否解析为特定的云提供商(AWS,Azure,GCP,Digital Ocean)?像这样:

# Returns 'Azure'
whichCloud('256.256.256.256')

解决方法

虽然您可以根据以下数据编写工具:

  1. 亚马逊-https://docs.aws.amazon.com/general/latest/gr/aws-ip-ranges.html
  2. GCP-https://cloud.google.com/compute/docs/faq#find_ip_range
  3. 天青-https://www.microsoft.com/en-us/download/details.aspx?id=56519

我不知道这样的事情。但是,您可以对其进行一些更改。例如,我的房东在亚马逊上。我可以做一个whois my.ip.addr.ess并且得到:

$ whois my.ip.is.here

#
# ARIN WHOIS data and services are subject to the Terms of Use
# available at: https://www.arin.net/resources/registry/whois/tou/
#
# If you see inaccuracies in the results,please report at
# https://www.arin.net/resources/registry/whois/inaccuracy_reporting/
#
# Copyright 1997-2020,American Registry for Internet Numbers,Ltd.
#


NetRange:       52.0.0.0 - 52.31.255.255
CIDR:           52.0.0.0/11
NetName:        AT-88-Z
NetHandle:      NET-52-0-0-0-1
Parent:         NET52 (NET-52-0-0-0-0)
NetType:        Direct Allocation
OriginAS:       
Organization:   Amazon Technologies Inc. (AT-88-Z)
RegDate:        1991-12-19
Updated:        2015-03-20
Ref:            https://rdap.arin.net/registry//ip/52.0.0.0

其他环境应该相似。这不是您想要的,但它可能会使您更接近。

相关问答

依赖报错 idea导入项目后依赖报错,解决方案:https://blog....
错误1:代码生成器依赖和mybatis依赖冲突 启动项目时报错如下...
错误1:gradle项目控制台输出为乱码 # 解决方案:https://bl...
错误还原:在查询的过程中,传入的workType为0时,该条件不起...
报错如下,gcc版本太低 ^ server.c:5346:31: 错误:‘struct...