ExportXMLWordPrintableJSON

    • Type: New Feature
    • Resolution: Fixed
    • Priority: Major - P3
    • 2.6.0
    • Affects Version/s: None
    • Component/s: QE/CSFLE
    • None
    • 2
    • None
    • PHP Drivers
    • Needed
    • Hide

      1. What would you like to communicate to the user about this feature?

      New constants available for string queryable encryption

      2. Would you like the user to see examples of the syntax and/or executable code and its output?

      3. Which versions of the driver/connector does this apply to?

      MongoDB Extension 2.6.0

      Show
      1. What would you like to communicate to the user about this feature? New constants available for string queryable encryption 2. Would you like the user to see examples of the syntax and/or executable code and its output? 3. Which versions of the driver/connector does this apply to? MongoDB Extension 2.6.0
    • None
    • None
    • None
    • None
    • None
    • None

      Context

      PHPC-2728 added the stringOpts option to MongoDB\Driver\ClientEncryption::encrypt(). To use it, users must pass literal strings for algorithm and queryType, because no constants exist for the new values, unlike ALGORITHM_INDEXED, ALGORITHM_RANGE or QUERY_TYPE_RANGE.

      Proposal

      Add the following constants to MongoDB\Driver\ClientEncryption in [ClientEncryption.stub.php|https://github.com/mongodb/mongo-php-driver/blob/v2.x/src/MongoDB/ClientEncryption.stub.php], backed by the libmongoc macros when available:

      Constant Value
      ALGORITHM_STRING "String"
      QUERY_TYPE_PREFIX "prefix"
      QUERY_TYPE_SUFFIX "suffix"
      QUERY_TYPE_SUBSTRING "substring"

      Also update the generated arginfo, the tests, and the PHP manual (encrypt() options and class constants).

            Assignee:
            Jérôme Tamarelle
            Reporter:
            Jérôme Tamarelle
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: