Uploaded image for project: 'Couchbase Python Client Library'
  1. Couchbase Python Client Library
  2. PYCBC-1300

Usability: provide better error message when CA cert doesn't match

    XMLWordPrintable

Details

    • Bug
    • Resolution: Unresolved
    • Major
    • None
    • None
    • None
    • None
    • 1

    Description

      If I connect over TLS and provide the wrong CA cert with the python client, I get this error:

      Traceback (most recent call last):
        File "/Users/davefinlay/work1/clients/xattr.py", line 56, in <module>
          cluster = Cluster(conn_str, ClusterOptions(authenticator))
        File "/usr/local/lib/python3.9/site-packages/couchbase/cluster.py", line 577, in __init__
          super(Cluster, self).__init__(
        File "/usr/local/lib/python3.9/site-packages/couchbase_core/client.py", line 160, in __init__
          self._do_ctor_connect()
        File "/usr/local/lib/python3.9/site-packages/couchbase/cluster.py", line 602, in _do_ctor_connect
          super(Cluster, self)._do_ctor_connect(*args, **kwargs)
        File "/usr/local/lib/python3.9/site-packages/couchbase_core/client.py", line 169, in _do_ctor_connect
          self._connect()
      couchbase.exceptions.LCB_0x3EB (generated, catch: SDKException): <RC=0x3EB[LCB_ERR_SSL_CANTVERIFY (1003)], There was a problem while trying to send/receive your request over the network. This may be a result of a bad network or a misconfigured client or server, C Source=(src/bucket.c,1227)>
      

      The LCB_ERR_SSL_CANTVERIFY is good, but the rest of the error message could be a lot better as it points to some vague generic networking problems. The error message should restate that the certificate can't be verified and ask that the client configuration be checked.

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            jared.casey Jared Casey
            dfinlay Dave Finlay
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:

              Gerrit Reviews

                There are no open Gerrit changes

                PagerDuty