Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-54187

Tests should not create invalid binary data

    XMLWordPrintableJSON

Details

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major - P3 Major - P3
    • 5.1.0-rc0
    • None
    • None
    • None
    • Fully Compatible
    • ALL
    • Repl 2021-08-23, Repl 2021-09-06
    • 17

    Description

      Certain tests create BinData fields of subtype 2,3, or 4 without meeting the requirements of those fields. Bindata types 3 and 4 are UUID and must be 16 bytes long. BinData type 2 is a deprecated type which must start with a 4-byte length equal to the length of the rest of the field. The server and the shell do not check this, but the Python driver does; the C driver at least checks type 2. If invalid entries are in the database, our python test fixtures will fail if they ever see them, so these must be removed.

      These invalid entries exist at least in

      jstests/core/bindata_eq.js
      jstests/core/in_with_mixed_values.js
      jstests/core/bittest.js

      The UUIDs BinData(3, "OEJTfmD8twzaj/LPKLIVkA==") in jstests/core/binData.js and BinData(4, "QlLfPHTySm6tqfuV+EOsVA==") in http://morningstar/mongodb/source/jstests/auth/kill_cursors.js are valid.

      Attachments

        Activity

          People

            adi.zaimi@mongodb.com Adi Zaimi
            matthew.russotto@mongodb.com Matthew Russotto
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: