Uploaded image for project: 'Python Driver'
  1. Python Driver
  2. PYTHON-2192

Clarify hostname canonicalization logic.

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major - P3
    • Resolution: Fixed
    • None
    • 3.11
    • Auth
    • None

    Description

      Currently, the canonicalization logic for some host addresses gets different results in java and python (the current c# version has the same results as python, but the ticket is still not finished).

      To check it, I used python code which is provided in the description of spec ticket: SPEC-1040 and the following java code:

      InetAddress.getByName(serverAddress.getHost()).getCanonicalHostName()
      

      from https://github.com/mongodb/mongo-java-driver/blob/master/driver-core/src/main/com/mongodb/internal/connection/GSSAPIAuthenticator.java#L98

      See, this google doc with the results: https://docs.google.com/document/d/145oeuIYo-2OMmZC8P68LaPI_RfSuaQw3buC_yKB9qb0.
      In two words, the canonicalization logic for the host azure.microsoft.com returns different results for java and python:

      • Python result: l-0007.l-msedge.net
      • Java result: 13.107.42.16

      The target of this ticket is to determine which result is correct/expected. Also, it would be great to add more test hostnames to check this behavior.

       

      Attachments

        Issue Links

          Activity

            People

              bernie@mongodb.com Bernie Hackett
              dmitry.lukyanov@mongodb.com Dmitry Lukyanov
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: