Gem omniauth 登录报 SSL 错误?

cdredfox · March 05, 2013 · Last by ywjno replied at March 05, 2013 · 2118 hits

准备写个 omniauth 的 taobao 登录 gem,但是我在 callback 阶段总是出现这样的错误:

SSL_connect returned=1 errno=0 state=SSLv3 read server certificate B: certificate verify failed

大家有碰到过这样的情况吗?

网上 google 了一大把,说需要证书?

加上如下代码试试

module OpenSSL
  module SSL
    remove_const :VERIFY_PEER
  end
end
OpenSSL::SSL::VERIFY_PEER = OpenSSL::SSL::VERIFY_NONE
You need to Sign in before reply, if you don't have an account, please Sign up first.