Fix Certificate Verify Failed in Ruby

If you install ruby with RubyInstaller, when trying to pull updates from RubyGems, you maybe occur error SSL error certificate verify failed. This post help you fix this issue or upgrades SSL on

  • Full error message of certificate verify failed

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

    RubyGems requires to bundle the trust certificates, which allow RubyGems to establish a connection to servers even when base operating system is unable to verify the identity of them.

    This certificate was provided by one CA, but newer certificate is provided by a different one.

    Only RubyGems 2.4.4 got released, while Ruby installation with 1.8, 2.0, 2.2 in a broken state, since RubyGems 2.4 is broken on Windows.

  • Fix certificate verify failed in ruby

    You can fix this issue by installing update packages.

    Now that RubyGems 1.8.x, 2.0.x and 2.2.x have been released, you can manually update to those versions.

    Download the proper version of RubyGems for your installation (eg. if running version 1.8.28, download 1.8.30, check running verrion with gem --version).

    You can find download links at GitHub under Releases.

    Now, manually update by using your Command Prompt

    C:\>gem install --local C:\rubygems-update-1.8.30.gem
    C:\>update_rubygems --no-ri --no-rdoc


Popular posts from this blog