【发布时间】:2015-08-09 08:03:50
【问题描述】:
我正在使用 Google API 库在我们一直在构建的 Web 应用程序中进行服务器到服务器的通信。它适用于我们的开发和测试服务器,但是,当我们将应用程序移至生产环境时,尝试获取 Oauth2 令牌时,Curl 命令会导致连接被拒绝。
在我们的开发和测试服务器上:
curl -v https://accounts.google.com/o/oauth2/token
成功,并返回完整的 405 响应
在我们的生产服务器上,curl 命令导致
curl -v https://accounts.google.com/o/oauth2/token
* About to connect() to accounts.google.com port 443 (#0)
* Trying 216.58.216.205... Connection refused
* Trying 2607:f8b0:4009:808::200d... Failed to connect to 2607:f8b0:4009:808::200d: Network is unreachable
* Success
* couldn't connect to host
* Closing connection #0
curl: (7) Failed to connect to 2607:f8b0:4009:808::200d: Network is unreachable
谷歌是否将我们的网站列入黑名单?所有这些服务器都在同一个域中。
【问题讨论】: