Skip to content

Commit 9cb8ad6

Browse files
authored
DOCSP-23032 ensure FLE2 options are passed through to driver (#1417)
* ensure FLE2 options are passed through to driver * internal review * external review feedback * external review feedback
1 parent ffea940 commit 9cb8ad6

File tree

2 files changed

+36
-3
lines changed

2 files changed

+36
-3
lines changed

source/reference/method/ClientEncryption.encrypt.txt

Lines changed: 24 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -61,19 +61,40 @@ ClientEncryption.encrypt()
6161

6262
- The value to encrypt.
6363

64-
* - ``encryptionAlgorithm``
64+
* - ``encryptionAlgorithm`` or ``encryptionOptions``
6565

66-
- string
66+
- string or document
6767

68-
- The encryption algorithm to use for encrypting the ``value``.
68+
- When specifying ``encryptionAlgorithm``:
69+
70+
The encryption algorithm to use for encrypting the ``value``.
6971

7072
- ``AEAD_AES_256_CBC_HMAC_SHA_512-Deterministic``
7173

7274
- ``AEAD_AES_256_CBC_HMAC_SHA_512-Random``
75+
76+
- ``Indexed``
77+
78+
- ``Unindexed``
7379

7480
For complete documentation on the supported encryption
7581
algorithms, see :ref:`field-level-encryption-algorithms`.
7682

83+
- When specifying ``encryptionOptions``:
84+
85+
- ``algorithm``: The encryption algorithm to use for
86+
encrypting the ``value``.
87+
88+
- ``keyId``: ID of the data decryption key.
89+
90+
- ``contentionFactor``: Required when ``algorithm`` is set
91+
to ``Indexed``. Related to the frequency of the values for
92+
this field.
93+
94+
- ``queryType``: The only query type currently supported is
95+
``"equality"``. ``queryType`` must be set when algorithm is
96+
not ``Indexed``.
97+
7798
:returns:
7899

79100
A :bsontype:`binary data <Binary>` object with

source/reference/method/KeyVault.createKey.txt

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -148,6 +148,18 @@ KeyVault.createKey()
148148
<index-type-partial>` filter for only documents where
149149
``keyAltNames`` exists.
150150

151+
* - ``options``
152+
- document
153+
- *Optional*
154+
155+
A document that specifies options for the new key.
156+
``options`` has the following fields:
157+
158+
- ``masterKey``: the new master key to encrypt data.
159+
- ``keyAltNames``: an array of alternate names, one per
160+
master key.
161+
- ``keyMaterial``: bindata used to create the key.
162+
151163
:returns:
152164

153165
The ``UUID`` unique identifier of the created data encryption

0 commit comments

Comments
 (0)