Uploaded image for project: 'Ruby Driver'
  1. Ruby Driver
  2. RUBY-1391

Ruby driver returns generic OpenSSL error message rather than the actual one

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major - P3
    • Resolution: Fixed
    • Affects Version/s: 2.6.0
    • Fix Version/s: 2.6.1
    • Component/s: Authentication
    • Labels:
      None
    • Case:

      Description

      The Ruby driver catches all OpenSSL-related errors and returns the generic "SSL handshake failed. MongoDB may not be configured with SSL support.". The actual error is discarded making debugging difficult.

      https://github.com/mongodb/mongo-ruby-driver/blob/master/lib/mongo/socket.rb#L288-L290

      We should pass back the inner error message so that it can be logged in a manner similar to the following:

      rescue OpenSSL::SSL::SSLError => e
        raise Mongo::Error::SocketError, "#{Mongo::Socket::SSL::SSL_ERROR} (#{e.message})"
      end
      

        Attachments

          Activity

            People

            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: