Uploaded image for project: 'C Driver'
  1. C Driver
  2. CDRIVER-630

default_stream_initiator can block forever in TLS handshake

    • Type: Icon: Bug Bug
    • Resolution: Done
    • Priority: Icon: Major - P3 Major - P3
    • 1.2-beta0, 1.1.5
    • Affects Version/s: 1.1.4
    • Component/s: None
    • None

      *UPDATE*: Fixed in 1.1.5, still reproducible in 1.2.0. Uncomment the "/TLS/handshake_stall" test and fix in 1.2.0-dev branch.

      The default stream initiator in mongoc_client.c makes a blocking call to mongoc_stream_tls_do_handshake(). This can cause the driver to full hang until some kind of network error is returned.

      https://github.com/mongodb/mongo-c-driver/blob/master/src/mongoc/mongoc-client.c#L339

      We should pull connecttimeoutms or sockettimeoutms out of the uri and use that in lieu of permanent blocking.

            Assignee:
            bjori Hannes Magnusson
            Reporter:
            mira.carey@mongodb.com Mira Carey
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: