Ruby on Rails 中的 SSL 错误 OmniAuth
我已经阅读了很多有关此错误的内容,尤其是在 OmniAuth for Rails 3 中。我有几个问题,因为目前我陷入了困境。
这篇文章中的共识< /a> 是它无法正确引用证书。我的第一个问题是(我使用 Windows 7 来回答这个问题):
我应该在硬盘驱动器的哪个位置开始寻找证书?我使用 RailsInstaller 来安装 Rails 3,我能找到的唯一靠近该位置的东西是在“Git”中,其中有一个包含 ca-path 文件的“cert”目录。然而,大多数人拥有的参考是“/etc/certs/”或其他东西(基本上是相对网址)。我的问题是引用它的父目录在哪里?这可能非常简单,但我就是不知道。它是 C:/ 目录中我的 RailsInstaller 文件夹吗?
I've read a lot about this error especially in OmniAuth for Rails 3. I have a few questions because currently I'm stuck on it.
The consensus in this post was that it couldn't reference the certs properly. My first question is this (I'm using Windows 7 to preface the question):
Where exactly in my hard drive would I begin to look to find the certs? I used RailsInstaller to install Rails 3 and the only thing that I can find that is close to that location is in "Git" where there is a "cert" directory with the ca-path file. However, the reference that most people have is this "/etc/certs/" or something (basically a relative url). My question is where is the parent directory from which this is referenced? It may be extremely simple but I just don't know. Would it be my RailsInstaller folder in the C:/ directory?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
在我的 config\initializers\devise.rb
文件 cacert.pem 中,来自 http://curl.haxx.se/ca / 放入您的 Rails 应用程序配置目录,
感谢以下帖子:
为什么在 Windows 上使用 Mechanize 访问 SSL 站点失败,但在 Mac 上却可以?
http://grokbase.com/p/gg/rubyonrails-talk/121bfxzwke/rails-re-windows-rails-3-1-3-omniauth-browserid-ssl-erro
In my config\initializers\devise.rb
file cacert.pem from http://curl.haxx.se/ca/ put to your rails app config directory
thanks to this posts:
Why does accessing a SSL site with Mechanize on Windows fail, but on Mac work?
http://grokbase.com/p/gg/rubyonrails-talk/121bfxzwke/rails-re-windows-rails-3-1-3-omniauth-browserid-ssl-erro
您好,Vivek,我在 Windows 7 上解决了这个问题,
您可以从这里获取证书:
https://gist.github.com/fnichol/867550
因此该证书的位置将是< strong>C:\RailsInstaller\cacert.pem
完整映像:config\initializers\omniauth.rb
Hi Vivek I resolve this issue on windows 7,
you can get certificate from here:
https://gist.github.com/fnichol/867550
So location for this certificate will be C:\RailsInstaller\cacert.pem
Full image: config\initializers\omniauth.rb