如何证明指定AWS区域中的数据实际上位于该区域?

时间:2018-04-26 17:36:36

标签: amazon-web-services amazon-s3

我们有业务要求确认存储在特定AWS区域(ca-central-1)中的数据实际存储在加拿大。有没有办法通过AWS或其他方式来确认这一点?理想情况下,我们希望指向一个网页,向客户显示他们的数据实际上是在该国家(加拿大)。理想情况下,我们可以显示AWS控制台的屏幕截图,显示客户端在ca-central-1区域的EC2和S3,但我们正在寻找更“官方”的内容。

2 个答案:

答案 0 :(得分:0)

您可以使用dnslookup命令。以下将给你ip

dig +nocmd your.cloud any +multiline +noall +answer

然后您可以使用以下命令获取该区域:

curl freegeoip.net/xml/xx.xxx.xxx.xxx

这将为您提供地址的地理位置。如果有帮助,您也可以使用他们的website

测试时使用:curl freegeoip.net/xml/54.231.184.255

回复:

<Response> <DeprecationMessage>This API endpoint is deprecated and will stop working on July 1st, 2018. For more information please visit: https://github.com/apilayer/freegeoip#readme</DeprecationMessage> <IP>54.231.184.255</IP> <CountryCode>US</CountryCode> <CountryName>United States</CountryName> <RegionCode>OR</RegionCode> <RegionName>Oregon</RegionName> <City>Boardman</City> <ZipCode>97818</ZipCode> <TimeZone>America/Los_Angeles</TimeZone> <Latitude>45.7788</Latitude> <Longitude>-119.529</Longitude> <MetroCode>810</MetroCode> </Response>

答案 1 :(得分:0)

freegeoip将在几个月后停止工作。

以下是另一种选择:https://geocoder.ca/54.231.184.255?geoit=xml

    <geodata>
    <latt>47.584095 </latt>
    <longt>-122.299566      </longt>
    <city>Mercer Island     </city>
    <prov>WA        </prov>
    <postal>98040   </postal>
    <stnumber>2121  </stnumber>
    <staddress>26TH AVE S   </staddress>
    <inlatt>47.5839 </inlatt>
    <inlongt>-122.2995      </inlongt>
    <distance>0.022 </distance>
    <NearRoad>25TH AVE S    </NearRoad>
    <NearRoadDistance>0.010 </NearRoadDistance>
    <neighborhood>Atlantic  </neighborhood>
    <TimeZone>America/Los_Angeles   </TimeZone>
    <AreaCode>206   </AreaCode>
    <confidence>0.9 </confidence>
    <intersection>
    <street1>26th Ave S     </street1>
    <street2>Walker St S    </street2>
    <lattx>47.583643        </lattx>
    <longtx>-122.299038     </longtx>
    <city>Mount Baker       </city>
    <prov>WA        </prov>
    <distance>0.045 </distance>
    </intersection>
    <major_intersection>
    <street1>Walker St S    </street1>
    <street2>25th Ave       </street2>
    <lattx>47.5835200000    </lattx>
    <longtx>-122.3001360000 </longtx>
    <city>Seattle   </city>
    <prov>WA        </prov>
    <distance>0.064 </distance>
    </major_intersection>
    <usa>
    <latt>47.5840948        </latt>
    <longt>-122.2995659     </longt>
    <uscity>Mercer Island   </uscity>
    <state>WA       </state>
    <zip>98040      </zip>
    <usstnumber>2121        </usstnumber>
    <usstaddress>26TH AVE S </usstaddress>
    <inlatt>47.5839 </inlatt>
    <inlongt>-122.2995      </inlongt>
    <distance>0.022 </distance>
    <NearRoad>25TH AVE S    </NearRoad>
    <NearRoadDistance>0.010 </NearRoadDistance>
    <neighborhood>Atlantic  </neighborhood>
    <TimeZone>America/Los_Angeles   </TimeZone>
    <AreaCode>206   </AreaCode>
    <confidence>0.9 </confidence>
    <intersection>
    <street1>26th Ave S     </street1>
    <street2>Walker St S    </street2>
    <lattx>47.583643        </lattx>
    <longtx>-122.299038     </longtx>
    <city>Mount Baker       </city>
    <prov>WA        </prov>
    <distance>0.045 </distance>
    </intersection>
    <major_intersection>
    <street1>Walker St S    </street1>
    <street2>25th Ave       </street2>
    <lattx>47.5835200000    </lattx>
    <longtx>-122.3001360000 </longtx>
    <city>Seattle   </city>
    <prov>WA        </prov>
    <distance>0.064 </distance>
    </major_intersection>
    <usa>
    <latt>47.5840948        </latt>
    <longt>-122.2995659     </longt>
    <uscity>Mercer Island   </uscity>
    <state>WA       </state>
    <zip>98040      </zip>
    <usstnumber>2121        </usstnumber>
    <usstaddress>26TH AVE S </usstaddress>
    <inlatt>47.5839 </inlatt>
    <inlongt>-122.2995      </inlongt>
    <distance>0.022 </distance>
    </usa>
    </geodata>