[COMPASS-2208] SSL-related error are not reported properly in Compass Created: 25/Jul/16  Updated: 02/Mar/20  Resolved: 02/Mar/20

Status: Closed
Project: Compass
Component/s: Connectivity
Affects Version/s: 1.5.0-dev
Fix Version/s: 1.21.0

Type: Bug Priority: Major - P3
Reporter: Dmitry Ryabtsev Assignee: Lucas Hrabovsky (Inactive)
Resolution: Done Votes: 1
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Attachments: PNG File OSX.png     PNG File Windows.png     PNG File scr.png    
Issue Links:
Related
is related to NODE-782 SSL validation may fail depending on ... Closed
Epic Link: INT-436
Sprint: INT 2016-08-26, INT 2016-09-16, INT 2016-10-07

 Description   

This seems to be an issue with 1.3-beta version only. Applies to both Windows and OSX.

Consider the example in the attached screenshots - they show an attempt to connect with an invalid CA file. On 1.2 the error message says "Invalid or missing certificate" while on 1.3-beta, it's a generic "Could not connect message ..."



 Comments   
Comment by Lucas Hrabovsky (Inactive) [ 02/Mar/20 ]

The updated connect dialog no longer attempts to translate driver error messages and this commit in the driver ensures ssl/tls errors are raised with the highest fidelity error message.

Handle rogue SSL exceptions.

In the case of an invalid private key, the core node tls module raises
the exception instead of emitting an error event like all other errors.
This addresses this case and other potential anomalies.

Comment by Massimiliano Marcon [ 07/Mar/19 ]

Closing because it has not been updated for more than 1 year and the corresponding customer case has been closed with satisfactory resolution.

Comment by Peter Schmidt [ 21/Oct/17 ]

dmitry.ryabtsev As this ticket still looks valid, perhaps move this ticket to the COMPASS project?

If it's important, you might also wish to resolve it yourself, the place I'd start today if I were still working on Compass would be: https://github.com/10gen/compass-connect

Comment by Dmitry Ryabtsev [ 11/Feb/17 ]

This is still an issue in Compass 1.5.1 - in my recent tests I failed to connect due to hostname validation failure, but all Compass shows to the user is the "Could not connect..." message.

It is worth mentioning that I failed to dig up the connection failure reason from the Compass' console - it does not seem very useful for diagnosing SSL connectivity issues. Would be nice if Compass could report proper error messages in the UI.

Comment by Matt Kangas [ 16/Aug/16 ]

Based on Dimitry's description, I thought it would be INT-1331 ("Error messages from the node.js driver are human readable"). It seems as if the detailed driver message is mapped to a generic message, perhaps accidentally.

But INT-1331 landed in 1.2.0-dev - so I'm puzzled.

Comment by Dmitry Ryabtsev [ 15/Aug/16 ]

Hi lucas.hrabovsky,

This ticket was raised to address a problem that looks like a regression to me - 1.3-beta does not report the connection failure reason in the same way as 1.2 does. I don't think it's related to NODE-782.

Just wanted to make it clear.

PS It's good to know that there will be a way to get a detailed diagnostic info in future.

Comment by Lucas Hrabovsky (Inactive) [ 15/Aug/16 ]

The source of this is NODE-782 which being closed as won't fix will be the same resolution here. However, INT-1692 will make these type of errors much more transparent to the user and make it easier for customer's to translate this diagnostic info when creating CS tickets.

Generated at Wed Feb 07 22:29:21 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.