Show More
@@ -430,6 +430,7 b' def wrapsocket(sock, keyfile, certfile, ' | |||||
430 | 'error)\n')) |
|
430 | 'error)\n')) | |
431 | except ssl.SSLError: |
|
431 | except ssl.SSLError: | |
432 | pass |
|
432 | pass | |
|
433 | ||||
433 | # Try to print more helpful error messages for known failures. |
|
434 | # Try to print more helpful error messages for known failures. | |
434 | if util.safehasattr(e, 'reason'): |
|
435 | if util.safehasattr(e, 'reason'): | |
435 | # This error occurs when the client and server don't share a |
|
436 | # This error occurs when the client and server don't share a | |
@@ -437,7 +438,7 b' def wrapsocket(sock, keyfile, certfile, ' | |||||
437 | # outright. Hopefully the reason for this error is that we require |
|
438 | # outright. Hopefully the reason for this error is that we require | |
438 | # TLS 1.1+ and the server only supports TLS 1.0. Whatever the |
|
439 | # TLS 1.1+ and the server only supports TLS 1.0. Whatever the | |
439 | # reason, try to emit an actionable warning. |
|
440 | # reason, try to emit an actionable warning. | |
440 | if e.reason == 'UNSUPPORTED_PROTOCOL': |
|
441 | if e.reason == r'UNSUPPORTED_PROTOCOL': | |
441 | # We attempted TLS 1.0+. |
|
442 | # We attempted TLS 1.0+. | |
442 | if settings['protocolui'] == 'tls1.0': |
|
443 | if settings['protocolui'] == 'tls1.0': | |
443 | # We support more than just TLS 1.0+. If this happens, |
|
444 | # We support more than just TLS 1.0+. If this happens, | |
@@ -484,7 +485,7 b' def wrapsocket(sock, keyfile, certfile, ' | |||||
484 | '(see https://mercurial-scm.org/wiki/SecureConnections ' |
|
485 | '(see https://mercurial-scm.org/wiki/SecureConnections ' | |
485 | 'for more info)\n')) |
|
486 | 'for more info)\n')) | |
486 |
|
487 | |||
487 | elif (e.reason == 'CERTIFICATE_VERIFY_FAILED' and |
|
488 | elif (e.reason == r'CERTIFICATE_VERIFY_FAILED' and | |
488 | pycompat.iswindows): |
|
489 | pycompat.iswindows): | |
489 |
|
490 | |||
490 | ui.warn(_('(the full certificate chain may not be available ' |
|
491 | ui.warn(_('(the full certificate chain may not be available ' |
General Comments 0
You need to be logged in to leave comments.
Login now