“标准”Windows修复程序无法解决SSL问题。为什么?

时间:2016-06-02 01:43:00

标签: gcloud-ruby

我在Windows 10计算机上使用gcloud在本地运行应用程序时出现问题。我收到以下错误:

C:/Ruby23-x64/lib/ruby/2.3.0/net/http.rb:933:in `connect_nonblock': SSL_connect returned=1 errno=0 state=SSLv3 read server certificate B: certificate verify failed (Faraday::SSLError)
    from C:/Ruby23-x64/lib/ruby/2.3.0/net/http.rb:933:in `connect'
    from C:/Ruby23-x64/lib/ruby/2.3.0/net/http.rb:863:in `do_start'
    from C:/Ruby23-x64/lib/ruby/2.3.0/net/http.rb:852:in `start'
    from C:/Ruby23-x64/lib/ruby/2.3.0/net/http.rb:1398:in `request'
    from C:/Ruby23-x64/lib/ruby/gems/2.3.0/gems/faraday-0.9.2/lib/faraday/adapter/net_http.rb:82:in `perform_request'
    from C:/Ruby23-x64/lib/ruby/gems/2.3.0/gems/faraday-0.9.2/lib/faraday/adapter/net_http.rb:40:in `block in call'
    from C:/Ruby23-x64/lib/ruby/gems/2.3.0/gems/faraday-0.9.2/lib/faraday/adapter/net_http.rb:87:in `with_net_http_connection'
    from C:/Ruby23-x64/lib/ruby/gems/2.3.0/gems/faraday-0.9.2/lib/faraday/adapter/net_http.rb:32:in `call'
    from C:/Ruby23-x64/lib/ruby/gems/2.3.0/gems/faraday-0.9.2/lib/faraday/request/url_encoded.rb:15:in `call'
    from C:/Ruby23-x64/lib/ruby/gems/2.3.0/gems/faraday-0.9.2/lib/faraday/rack_builder.rb:139:in `build_response'
    from C:/Ruby23-x64/lib/ruby/gems/2.3.0/gems/faraday-0.9.2/lib/faraday/connection.rb:377:in `run_request'
    from C:/Ruby23-x64/lib/ruby/gems/2.3.0/gems/faraday-0.9.2/lib/faraday/connection.rb:177:in `post'
    from C:/Ruby23-x64/lib/ruby/gems/2.3.0/gems/signet-0.7.2/lib/signet/oauth_2/client.rb:960:in `fetch_access_token'
    from C:/Ruby23-x64/lib/ruby/gems/2.3.0/gems/signet-0.7.2/lib/signet/oauth_2/client.rb:998:in `fetch_access_token!'
    from C:/Ruby23-x64/lib/ruby/gems/2.3.0/gems/googleauth-0.5.1/lib/googleauth/signet.rb:69:in `fetch_access_token!'
    from C:/Ruby23-x64/lib/ruby/gems/2.3.0/gems/gcloud-0.7.2/lib/gcloud/credentials.rb:58:in `initialize'
    from C:/Ruby23-x64/lib/ruby/gems/2.3.0/gems/gcloud-0.7.2/lib/gcloud/credentials.rb:84:in `new'
    from C:/Ruby23-x64/lib/ruby/gems/2.3.0/gems/gcloud-0.7.2/lib/gcloud/credentials.rb:84:in `default'
    from C:/Ruby23-x64/lib/ruby/gems/2.3.0/gems/gcloud-0.7.2/lib/gcloud/datastore.rb:62:in `datastore'
    from C:/Ruby23-x64/lib/ruby/gems/2.3.0/gems/gcloud-0.7.2/lib/gcloud.rb:106:in `datastore'
    from app.rb:21:in `<main>'

我已经搜索了这个问题的答案。以下是这个问题答案的一个很好的例子: https://github.com/lostisland/faraday/issues/392

答案归结为我需要一个pem文件并告诉Ruby它与环境变量SSL_CERT_FILE的关系。

就我而言,它无效。

我该怎么解决这个问题?

0 个答案:

没有答案