Determine wire version and size limits from socket's ismaster, not server description

XMLWordPrintableJSON

    • Type: Bug
    • Resolution: Duplicate
    • Priority: Major - P3
    • None
    • Affects Version/s: None
    • Component/s: auth, libmongoc, network
    • None
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      Per https://github.com/mongodb/specifications/blob/master/source/server-discovery-and-monitoring/server-discovery-and-monitoring.rst#warning-about-the-maxwireversion-from-a-monitor-s-ismaster-response drivers should determine the supported wire version, maxBsonObjectSize, maxMessageSizeBytes, and maxWriteBatchSize from the initial handshake on a socket.

      libmongoc does store these fields on a cluster node, but does not appear to use them when constructing the commands (even for the initial auth handshake). Instead, it uses the most recent server description from the topology, which may result in a race as described in the section of SDAM above.

              Assignee:
              Unassigned
              Reporter:
              Kevin Albertson
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Created:
                Updated:
                Resolved: