Uploaded image for project: 'Compass '
  1. Compass
  2. COMPASS-6258

Investigate changes in NODE-4770: Remove UTF8 length 12 strings from ObjectId constructor

    XMLWordPrintableJSON

Details

    • Icon: Investigation Investigation
    • Resolution: Done
    • Icon: Major - P3 Major - P3
    • No version
    • None
    • None
    • Not Needed

    Description

      Details

      As of v4.2.0 ObjectId's began interpreting strings of length 12 as UTF8 instead of latin1. We should remove support for strings that aren't exactly hex strings to make construction from string input clear and lack a variation of interpretations.

      AC

      • Only allow strings of length 24 that contain hex characters
      • Remove strings of length 12 from objectId constructor
      • Update tests

      Attachments

        Activity

          People

            Unassigned Unassigned
            dbeng-pm-bot PM Bot
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: