libmongocrypt-helper 1.12.0.0.1001 → 1.13.2.0.1001
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/ext/libmongocrypt/libmongocrypt/CHANGELOG.md +19 -0
- data/ext/libmongocrypt/libmongocrypt/CMakeLists.txt +10 -0
- data/ext/libmongocrypt/libmongocrypt/CODEOWNERS +1 -4
- data/ext/libmongocrypt/libmongocrypt/CONTRIBUTING.md +14 -0
- data/ext/libmongocrypt/libmongocrypt/Earthfile +49 -50
- data/ext/libmongocrypt/libmongocrypt/README.md +8 -17
- data/ext/libmongocrypt/libmongocrypt/bindings/python/CHANGELOG.rst +6 -0
- data/ext/libmongocrypt/libmongocrypt/bindings/python/README.rst +1 -1
- data/ext/libmongocrypt/libmongocrypt/bindings/python/libmongocrypt-version.txt +1 -1
- data/ext/libmongocrypt/libmongocrypt/bindings/python/pymongocrypt/binding.py +39 -1
- data/ext/libmongocrypt/libmongocrypt/bindings/python/pymongocrypt/mongocrypt.py +32 -0
- data/ext/libmongocrypt/libmongocrypt/bindings/python/pymongocrypt/version.py +1 -1
- data/ext/libmongocrypt/libmongocrypt/bindings/python/release.sh +1 -1
- data/ext/libmongocrypt/libmongocrypt/bindings/python/sbom.json +8 -8
- data/ext/libmongocrypt/libmongocrypt/bindings/python/test/data/compact/success/encrypted-field-config-map.json +0 -1
- data/ext/libmongocrypt/libmongocrypt/bindings/python/test/data/encrypted-field-config-map.json +0 -2
- data/ext/libmongocrypt/libmongocrypt/bindings/python/test/test_mongocrypt.py +11 -11
- data/ext/libmongocrypt/libmongocrypt/cmake/FetchMongoC.cmake +4 -2
- data/ext/libmongocrypt/libmongocrypt/cmake/ImportBSON.cmake +3 -5
- data/ext/libmongocrypt/libmongocrypt/doc/releasing.md +14 -27
- data/ext/libmongocrypt/libmongocrypt/etc/cyclonedx.sbom.json +9 -9
- data/ext/libmongocrypt/libmongocrypt/etc/format.sh +0 -2
- data/ext/libmongocrypt/libmongocrypt/etc/libbson-remove-GCC-diagnostic-in-functions.patch +158 -0
- data/ext/libmongocrypt/libmongocrypt/etc/libbson-remove-GCC-diagnostic-pragma.patch +3 -3
- data/ext/libmongocrypt/libmongocrypt/etc/purls.txt +1 -1
- data/ext/libmongocrypt/libmongocrypt/integrating.md +42 -11
- data/ext/libmongocrypt/libmongocrypt/kms-message/src/kms_crypto_windows.c +2 -2
- data/ext/libmongocrypt/libmongocrypt/kms-message/src/kms_message.c +1 -1
- data/ext/libmongocrypt/libmongocrypt/kms-message/src/kms_message_private.h +2 -2
- data/ext/libmongocrypt/libmongocrypt/kms-message/src/kms_request.c +3 -3
- data/ext/libmongocrypt/libmongocrypt/kms-message/test/test_kmip_reader_writer.c +5 -5
- data/ext/libmongocrypt/libmongocrypt/kms-message/test/test_kms_assert.h +25 -8
- data/ext/libmongocrypt/libmongocrypt/kms-message/test/test_kms_azure_online.c +2 -2
- data/ext/libmongocrypt/libmongocrypt/kms-message/test/test_kms_gcp_online.c +3 -3
- data/ext/libmongocrypt/libmongocrypt/kms-message/test/test_kms_request.c +12 -10
- data/ext/libmongocrypt/libmongocrypt/src/mc-efc-private.h +5 -0
- data/ext/libmongocrypt/libmongocrypt/src/mc-efc.c +35 -1
- data/ext/libmongocrypt/libmongocrypt/src/mc-fle-blob-subtype-private.h +4 -1
- data/ext/libmongocrypt/libmongocrypt/src/mc-fle2-encryption-placeholder-private.h +79 -0
- data/ext/libmongocrypt/libmongocrypt/src/mc-fle2-encryption-placeholder.c +226 -2
- data/ext/libmongocrypt/libmongocrypt/src/mc-fle2-find-equality-payload-v2.c +0 -1
- data/ext/libmongocrypt/libmongocrypt/src/mc-fle2-find-equality-payload.c +0 -1
- data/ext/libmongocrypt/libmongocrypt/src/mc-fle2-insert-update-payload-private-v2.h +34 -0
- data/ext/libmongocrypt/libmongocrypt/src/mc-fle2-insert-update-payload-v2.c +165 -1
- data/ext/libmongocrypt/libmongocrypt/src/mc-fle2-insert-update-payload.c +0 -1
- data/ext/libmongocrypt/libmongocrypt/src/mc-fle2-payload-iev-private-v2.h +105 -7
- data/ext/libmongocrypt/libmongocrypt/src/mc-fle2-payload-iev-v2.c +381 -70
- data/ext/libmongocrypt/libmongocrypt/src/mc-fle2-tag-and-encrypted-metadata-block-private.h +7 -2
- data/ext/libmongocrypt/libmongocrypt/src/mc-fle2-tag-and-encrypted-metadata-block.c +17 -0
- data/ext/libmongocrypt/libmongocrypt/src/mc-schema-broker-private.h +126 -0
- data/ext/libmongocrypt/libmongocrypt/src/mc-schema-broker.c +1075 -0
- data/ext/libmongocrypt/libmongocrypt/src/mc-str-encode-string-sets-private.h +95 -0
- data/ext/libmongocrypt/libmongocrypt/src/mc-str-encode-string-sets.c +304 -0
- data/ext/libmongocrypt/libmongocrypt/src/mc-text-search-str-encode-private.h +45 -0
- data/ext/libmongocrypt/libmongocrypt/src/mc-text-search-str-encode.c +248 -0
- data/ext/libmongocrypt/libmongocrypt/src/mc-tokens-private.h +112 -2
- data/ext/libmongocrypt/libmongocrypt/src/mc-tokens.c +166 -2
- data/ext/libmongocrypt/libmongocrypt/src/mlib/windows-lean.h +2 -0
- data/ext/libmongocrypt/libmongocrypt/src/mongocrypt-buffer-private.h +11 -0
- data/ext/libmongocrypt/libmongocrypt/src/mongocrypt-buffer.c +36 -3
- data/ext/libmongocrypt/libmongocrypt/src/mongocrypt-ctx-decrypt.c +8 -4
- data/ext/libmongocrypt/libmongocrypt/src/mongocrypt-ctx-encrypt.c +430 -857
- data/ext/libmongocrypt/libmongocrypt/src/mongocrypt-ctx-private.h +5 -19
- data/ext/libmongocrypt/libmongocrypt/src/mongocrypt-kms-ctx.c +1 -1
- data/ext/libmongocrypt/libmongocrypt/src/mongocrypt-marking.c +516 -523
- data/ext/libmongocrypt/libmongocrypt/src/mongocrypt-opts-private.h +0 -4
- data/ext/libmongocrypt/libmongocrypt/src/mongocrypt-private.h +7 -12
- data/ext/libmongocrypt/libmongocrypt/src/mongocrypt-traverse-util.c +1 -1
- data/ext/libmongocrypt/libmongocrypt/src/mongocrypt-util.c +3 -1
- data/ext/libmongocrypt/libmongocrypt/src/mongocrypt.c +6 -9
- data/ext/libmongocrypt/libmongocrypt/src/mongocrypt.h +17 -0
- data/ext/libmongocrypt/libmongocrypt/src/os_posix/os_dll.c +3 -1
- data/ext/libmongocrypt/libmongocrypt/src/unicode/case-fold-map.c +1434 -0
- data/ext/libmongocrypt/libmongocrypt/src/unicode/diacritic-fold-map.c +2884 -0
- data/ext/libmongocrypt/libmongocrypt/src/unicode/fold.c +139 -0
- data/ext/libmongocrypt/libmongocrypt/src/unicode/fold.h +58 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/bulkWrite/unencrypted/payload.json +2 -2
- data/ext/libmongocrypt/libmongocrypt/test/data/cleanup/missing-key-id/collinfo.json +1 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/cleanup/no-fields/collinfo.json +1 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/cleanup/success/collinfo.json +1 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/compact/anchor-pad/collinfo.json +1 -1
- data/ext/libmongocrypt/libmongocrypt/test/data/compact/anchor-pad/encrypted-payload-range-v2.json +20 -21
- data/ext/libmongocrypt/libmongocrypt/test/data/compact/missing-key-id/collinfo.json +2 -2
- data/ext/libmongocrypt/libmongocrypt/test/data/compact/no-fields/collinfo.json +1 -1
- data/ext/libmongocrypt/libmongocrypt/test/data/compact/no-range/collinfo.json +1 -1
- data/ext/libmongocrypt/libmongocrypt/test/data/compact/success/collinfo.json +1 -1
- data/ext/libmongocrypt/libmongocrypt/test/data/compact/success/encrypted-field-config-map.json +0 -1
- data/ext/libmongocrypt/libmongocrypt/test/data/compact/success/encrypted-payload-range-v2.json +20 -21
- data/ext/libmongocrypt/libmongocrypt/test/data/dollardb/omitted/cmd-to-mongocryptd.json +1 -2
- data/ext/libmongocrypt/libmongocrypt/test/data/dollardb/omitted/collinfo.json +2 -2
- data/ext/libmongocrypt/libmongocrypt/test/data/dollardb/omitted/encrypted-payload.json +2 -3
- data/ext/libmongocrypt/libmongocrypt/test/data/dollardb/omitted/mongocryptd-reply.json +1 -2
- data/ext/libmongocrypt/libmongocrypt/test/data/dollardb/preserved/cmd-to-mongocryptd.json +1 -2
- data/ext/libmongocrypt/libmongocrypt/test/data/dollardb/preserved/collinfo.json +2 -2
- data/ext/libmongocrypt/libmongocrypt/test/data/dollardb/preserved/encrypted-payload.json +2 -3
- data/ext/libmongocrypt/libmongocrypt/test/data/dollardb/preserved/mongocryptd-reply.json +1 -2
- data/ext/libmongocrypt/libmongocrypt/test/data/dollardb/preserved_empty/cmd-to-mongocryptd.json +1 -2
- data/ext/libmongocrypt/libmongocrypt/test/data/dollardb/preserved_empty/collinfo.json +2 -2
- data/ext/libmongocrypt/libmongocrypt/test/data/dollardb/preserved_empty/mongocryptd-reply.json +1 -2
- data/ext/libmongocrypt/libmongocrypt/test/data/dollardb/preserved_fle1/collinfo.json +2 -1
- data/ext/libmongocrypt/libmongocrypt/test/data/efc/efc-extraField.json +0 -1
- data/ext/libmongocrypt/libmongocrypt/test/data/efc/efc-missingKeyId.json +0 -1
- data/ext/libmongocrypt/libmongocrypt/test/data/efc/efc-oneField-badVersionSet.json +23 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/efc/efc-oneField-goodVersionSet.json +23 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/efc/efc-oneField.json +0 -1
- data/ext/libmongocrypt/libmongocrypt/test/data/efc/efc-textSearchFields-badVersionSet.json +48 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/efc/efc-textSearchFields-goodVersionSet.json +48 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/efc/efc-textSearchFields.json +47 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/efc/efc-twoFields.json +0 -1
- data/ext/libmongocrypt/libmongocrypt/test/data/encrypted-field-config-map.json +1 -3
- data/ext/libmongocrypt/libmongocrypt/test/data/explicit-decrypt/FLE1DeterministicEncryptedValue.json +8 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/explicit-decrypt/FLE1EncryptionPlaceholder.json +8 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/explicit-decrypt/FLE1RandomEncryptedValue.json +8 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/explicit-decrypt/FLE2EncryptionPlaceholder.json +8 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/explicit-decrypt/FLE2EqualityIndexedValueV2.json +8 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/explicit-decrypt/FLE2FindEqualityPayloadV2.json +8 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/explicit-decrypt/FLE2IndexedEqualityEncryptedValue.json +8 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/explicit-decrypt/FLE2IndexedEqualityEncryptedValueV2.json +8 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/explicit-decrypt/FLE2IndexedRangeEncryptedValue.json +8 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/explicit-decrypt/FLE2IndexedRangeEncryptedValueV2.json +8 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/explicit-decrypt/FLE2InsertUpdatePayload-with-edges-V2.json +8 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/explicit-decrypt/FLE2InsertUpdatePayload-with-edges.json +8 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/{fle2-explicit/insert-indexed.json → explicit-decrypt/FLE2InsertUpdatePayload.json} +1 -1
- data/ext/libmongocrypt/libmongocrypt/test/data/explicit-decrypt/FLE2InsertUpdatePayloadV2.json +8 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/explicit-decrypt/FLE2RangeIndexedValueV2.json +8 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/explicit-decrypt/FLE2UnindexedEncryptedValue.json +8 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/explicit-decrypt/FLE2UnindexedEncryptedValueV2.json +8 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/find-with-encryptionInformation.json +0 -1
- data/ext/libmongocrypt/libmongocrypt/test/data/fle1-explain/with-csfle/collinfo.json +2 -1
- data/ext/libmongocrypt/libmongocrypt/test/data/fle1-explain/with-mongocryptd/collinfo.json +2 -1
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-bad-str-encode-version/bad-collinfo.json +26 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-bad-str-encode-version/bad-create-cmd-mongocryptd-reply.json +51 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-bad-str-encode-version/bad-create-cmd-to-mongocryptd.json +45 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-bad-str-encode-version/bad-create-cmd.json +18 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/{fle2-find-range/int32/encrypted-field-map.json → fle2-bad-str-encode-version/bad-encrypted-field-config-map.json} +7 -12
- data/ext/libmongocrypt/libmongocrypt/test/data/{fle2-insert → fle2-bad-str-encode-version}/encrypted-payload.json +4 -4
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-create/cmd-to-mongocryptd.json +1 -2
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-create/encrypted-field-config-map.json +1 -2
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-create-encrypted-collection/cmd-to-mongocryptd.json +44 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-create-encrypted-collection/cmd.json +17 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/{fle2-find-equality/encrypted-field-map.json → fle2-create-encrypted-collection/encrypted-field-config-map.json} +9 -8
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-create-encrypted-collection/encrypted-payload.json +17 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-create-encrypted-collection/mongocryptd-reply.json +50 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-create-encrypted-collection-encrypted-fields-unset-str-encode-version/cmd-to-mongocryptd.json +45 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-create-encrypted-collection-encrypted-fields-unset-str-encode-version/mongocryptd-reply.json +51 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-create-encrypted-collection-with-str-encode-version/cmd-to-mongocryptd.json +46 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-create-encrypted-collection-with-str-encode-version/cmd.json +18 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-create-encrypted-collection-with-str-encode-version/encrypted-field-config-map.json +25 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-create-encrypted-collection-with-str-encode-version/encrypted-payload.json +18 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-create-encrypted-collection-with-str-encode-version/mongocryptd-reply.json +52 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-delete/empty/collinfo.json +1 -1
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-delete/empty/encrypted-field-config-map.json +0 -1
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-delete/empty/encrypted-payload-v2.json +57 -59
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-delete/empty/mongocryptd-reply.json +63 -64
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-delete/success/collinfo.json +1 -1
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-delete/success/encrypted-field-config-map.json +0 -1
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-delete/success/encrypted-payload-v2.json +64 -66
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-delete/success/mongocryptd-reply.json +69 -70
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-explain/with-csfle/collinfo.json +1 -1
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-explain/with-csfle/encrypted-payload.json +1 -2
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-explain/with-mongocryptd/cmd-to-mongocryptd.json +1 -2
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-explain/with-mongocryptd/collinfo.json +2 -2
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-explain/with-mongocryptd/encrypted-payload.json +2 -3
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-explain/with-mongocryptd/mongocryptd-reply.json +1 -2
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-find-explicit/cmd-to-mongocryptd.json +0 -1
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-find-explicit/cmd-to-mongod.json +0 -1
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-find-explicit/reply-from-mongocryptd.json +0 -1
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-insert-range/int32/encrypted-field-map.json +0 -1
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-insert-text-search/cmd.json +9 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/{fle2-find-range/date → fle2-insert-text-search}/encrypted-field-map.json +10 -9
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-insert-text-search/encrypted-payload.json +47 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-insert-text-search/mongocryptd-reply.json +55 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/{fle2-find-range/double → fle2-insert-text-search-with-str-encode-version}/encrypted-field-map.json +12 -10
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-insert-text-search-with-str-encode-version/encrypted-payload.json +47 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-insert-text-search-with-str-encode-version/mongocryptd-reply.json +55 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-insert-v2-with-str-encode-version/cmd.json +9 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/{fle2-insert → fle2-insert-v2-with-str-encode-version}/encrypted-field-map.json +2 -2
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-insert-v2-with-str-encode-version/encrypted-payload.json +40 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/{fle2-insert → fle2-insert-v2-with-str-encode-version}/mongocryptd-reply.json +2 -2
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-text-search-create-encrypted-collection/cmd-to-mongocryptd.json +55 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-text-search-create-encrypted-collection/cmd.json +22 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-text-search-create-encrypted-collection/encrypted-field-config-map.json +29 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-text-search-create-encrypted-collection/encrypted-payload.json +23 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-text-search-create-encrypted-collection/mongocryptd-reply.json +61 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-text-search-create-encrypted-collection-with-str-encode-version/cmd-to-mongocryptd.json +56 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-text-search-create-encrypted-collection-with-str-encode-version/cmd.json +23 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-text-search-create-encrypted-collection-with-str-encode-version/encrypted-field-config-map.json +30 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-text-search-create-encrypted-collection-with-str-encode-version/encrypted-payload.json +23 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-text-search-create-encrypted-collection-with-str-encode-version/mongocryptd-reply.json +62 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/iev-v2/FLECrudTest-insertOneText.json +20 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/iev-v2/FLECrudTest-insertOneTextLarge.json +930 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/csfle/cmd-to-mongocryptd.json +60 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/csfle/cmd.json +14 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/csfle/collInfo-c1.json +39 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/csfle/collInfo-c2.json +39 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/csfle-facet/cmd.json +20 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/csfle-mismatch/cmd.json +14 -0
- data/ext/libmongocrypt/libmongocrypt/{bindings/java/mongocrypt/src/test/resources/collection-info.json → test/data/lookup/csfle-mismatch/collInfo-c1.json} +13 -11
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/csfle-mismatch/collInfo-c3.json +39 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/csfle-nested/cmd.json +24 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/csfle-only-schemaMap/cmd-to-mongocryptd.json +60 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/csfle-only-schemaMap/cmd.json +14 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/csfle-only-schemaMap/schemaMap.json +40 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/csfle-schemaMap/cmd-to-mongocryptd.json +60 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/csfle-schemaMap/cmd.json +14 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/csfle-schemaMap/collInfo-c1.json +39 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/csfle-schemaMap/schemaMap.json +21 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/csfle-self/cmd-to-mongocryptd.json +34 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/csfle-self/cmd.json +14 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/csfle-self/collInfo-c1.json +39 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/csfle-sibling/cmd-to-mongocryptd.json +49 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/csfle-sibling/cmd.json +14 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/csfle-sibling/collInfo-c1.json +39 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/csfle-sibling/collInfo-c2.json +29 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/csfle-sibling/reply-from-mongocryptd.json +18 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/csfle-unionWith/cmd.json +21 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/csfle-view/cmd.json +14 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/csfle-view/collInfo-c1.json +39 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/csfle-view/collInfo-v1.json +11 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/csfle/csfle/cmd-to-mongocryptd.json +65 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/csfle/csfle/cmd-to-mongod.json +26 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/csfle/csfle/cmd.json +19 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/csfle/csfle/collInfo-c1.json +39 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/csfle/csfle/collInfo-c2.json +39 -0
- data/ext/libmongocrypt/libmongocrypt/{bindings/java/mongocrypt/src/test/resources/keys/ABCDEFAB123498761234123456789012-local-document.json → test/data/lookup/mixed/csfle/csfle/key-doc.json} +4 -4
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/csfle/csfle/reply-from-mongocryptd.json +33 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/csfle/no-schema/cmd-to-mongocryptd.json +47 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/csfle/no-schema/cmd-to-mongod.json +26 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/csfle/no-schema/cmd.json +19 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/csfle/no-schema/collInfo-c1.json +39 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/csfle/no-schema/collInfo-c2.json +17 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/csfle/no-schema/key-doc.json +30 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/csfle/no-schema/reply-from-mongocryptd.json +33 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/csfle/qe/cmd-to-mongocryptd.json +70 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/csfle/qe/cmd.json +19 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/csfle/qe/collInfo-c1.json +39 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/csfle/qe/collInfo-c2.json +42 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/no-schema/csfle/cmd-to-mongocryptd.json +47 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/no-schema/csfle/cmd-to-mongod.json +26 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/no-schema/csfle/cmd.json +19 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/no-schema/csfle/collInfo-c1.json +17 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/no-schema/csfle/collInfo-c2.json +39 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/no-schema/csfle/key-doc.json +30 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/no-schema/csfle/reply-from-mongocryptd.json +33 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/no-schema/no-schema/cmd-to-mongocryptd.json +29 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/no-schema/no-schema/cmd-to-mongod.json +19 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/no-schema/no-schema/cmd.json +19 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/no-schema/no-schema/collInfo-c1.json +17 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/no-schema/no-schema/collInfo-c2.json +17 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/no-schema/no-schema/reply-from-mongocryptd.json +26 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/no-schema/qe/cmd-to-mongocryptd.json +53 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/no-schema/qe/cmd-to-mongod.json +58 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/no-schema/qe/cmd.json +19 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/no-schema/qe/collInfo-c1.json +17 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/no-schema/qe/collInfo-c2.json +42 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/no-schema/qe/key-doc.json +30 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/no-schema/qe/reply-from-mongocryptd.json +65 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/qe/csfle/cmd-to-mongocryptd.json +70 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/qe/csfle/cmd.json +19 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/qe/csfle/collInfo-c1.json +42 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/qe/csfle/collInfo-c2.json +39 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/qe/no-schema/cmd-to-mongocryptd.json +53 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/qe/no-schema/cmd-to-mongod.json +56 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/qe/no-schema/cmd.json +19 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/qe/no-schema/collInfo-c1.json +42 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/qe/no-schema/collInfo-c2.json +17 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/qe/no-schema/key-doc.json +30 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/qe/no-schema/reply-from-mongocryptd.json +63 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/qe/qe/cmd-to-mongocryptd.json +66 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/qe/qe/cmd-to-mongod.json +71 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/qe/qe/cmd.json +19 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/qe/qe/collInfo-c1.json +42 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/qe/qe/collInfo-c2.json +42 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/qe/qe/key-doc.json +30 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/mixed/qe/qe/reply-from-mongocryptd.json +78 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/qe/cmd-to-mongocryptd.json +61 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/qe/cmd-to-mongod.json +14 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/qe/cmd.json +14 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/qe/collInfo-c1.json +42 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/qe/collInfo-c2.json +42 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/qe/reply-from-mongocryptd.json +68 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/qe-encryptedFieldsMap/cmd-to-mongocryptd.json +66 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/qe-encryptedFieldsMap/cmd-to-mongod.json +71 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/qe-encryptedFieldsMap/cmd.json +19 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/qe-encryptedFieldsMap/collInfo-c1.json +42 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/{fle2-insert-unindexed/encrypted-field-map.json → lookup/qe-encryptedFieldsMap/encryptedFieldsMap.json} +6 -7
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/qe-encryptedFieldsMap/key-doc.json +30 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/qe-encryptedFieldsMap/reply-from-mongocryptd.json +78 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/qe-self/cmd-to-mongocryptd.json +46 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/qe-self/cmd-to-mongod.json +53 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/qe-self/cmd.json +19 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/qe-self/collInfo-c1.json +42 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/qe-self/key-doc.json +30 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/qe-self/reply-from-mongocryptd.json +58 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/qe-with-payload/cmd-to-mongocryptd.json +66 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/qe-with-payload/cmd-to-mongod.json +75 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/qe-with-payload/cmd.json +19 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/qe-with-payload/collInfo-c1.json +42 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/qe-with-payload/collInfo-c2.json +42 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/qe-with-payload/key-doc.json +30 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/lookup/qe-with-payload/reply-from-mongocryptd.json +78 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/{fle2-create/mongocryptd-ismaster.json → mongocryptd-ismaster-17.json} +1 -1
- data/ext/libmongocrypt/libmongocrypt/test/data/mongocryptd-ismaster-26.json +12 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/schema-broker/collinfo-encryptedFields.json +42 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/schema-broker/collinfo-encryptedFields2.json +42 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/schema-broker/collinfo-jsonSchema.json +43 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/schema-broker/collinfo-noSchema.json +21 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/schema-broker/create-with-jsonSchema.json +24 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/schema-broker/encryptedFields.json +20 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/schema-broker/encryptedFields2.json +20 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/schema-broker/encryptedFieldsMap.json +42 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/schema-broker/jsonSchema.json +19 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/schema-broker/jsonSchema2.json +19 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/schema-broker/schemaMap.json +40 -0
- data/ext/libmongocrypt/libmongocrypt/test/data/tokens/mc.json +28 -2
- data/ext/libmongocrypt/libmongocrypt/test/data/tokens/server.json +28 -2
- data/ext/libmongocrypt/libmongocrypt/test/test-mc-efc.c +70 -0
- data/ext/libmongocrypt/libmongocrypt/test/test-mc-fle2-encryption-placeholder.c +468 -0
- data/ext/libmongocrypt/libmongocrypt/test/test-mc-fle2-find-equality-payload-v2.c +20 -1
- data/ext/libmongocrypt/libmongocrypt/test/test-mc-fle2-payload-iev-v2.c +286 -24
- data/ext/libmongocrypt/libmongocrypt/test/test-mc-fle2-payload-iev.c +1 -1
- data/ext/libmongocrypt/libmongocrypt/test/test-mc-fle2-payload-iup-v2.c +23 -1
- data/ext/libmongocrypt/libmongocrypt/test/test-mc-fle2-payload-iup.c +24 -1
- data/ext/libmongocrypt/libmongocrypt/test/test-mc-fle2-payload-uev.c +2 -2
- data/ext/libmongocrypt/libmongocrypt/test/test-mc-fle2-rfds.c +2 -2
- data/ext/libmongocrypt/libmongocrypt/test/test-mc-fle2-tag-and-encrypted-metadata-block.c +36 -1
- data/ext/libmongocrypt/libmongocrypt/test/test-mc-range-edge-generation.c +6 -7
- data/ext/libmongocrypt/libmongocrypt/test/test-mc-range-encoding.c +32 -33
- data/ext/libmongocrypt/libmongocrypt/test/test-mc-range-mincover.c +58 -66
- data/ext/libmongocrypt/libmongocrypt/test/test-mc-rangeopts.c +2 -2
- data/ext/libmongocrypt/libmongocrypt/test/test-mc-schema-broker.c +1124 -0
- data/ext/libmongocrypt/libmongocrypt/test/test-mc-text-search-str-encode.c +1207 -0
- data/ext/libmongocrypt/libmongocrypt/test/test-mc-tokens.c +144 -37
- data/ext/libmongocrypt/libmongocrypt/test/test-mongocrypt-assert-match-bson.c +13 -14
- data/ext/libmongocrypt/libmongocrypt/test/test-mongocrypt-assert.h +21 -4
- data/ext/libmongocrypt/libmongocrypt/test/test-mongocrypt-buffer.c +25 -0
- data/ext/libmongocrypt/libmongocrypt/test/test-mongocrypt-cache.c +3 -2
- data/ext/libmongocrypt/libmongocrypt/test/test-mongocrypt-crypto-hooks.c +1 -1
- data/ext/libmongocrypt/libmongocrypt/test/test-mongocrypt-crypto.c +37 -7
- data/ext/libmongocrypt/libmongocrypt/test/test-mongocrypt-csfle-lib.c +21 -0
- data/ext/libmongocrypt/libmongocrypt/test/test-mongocrypt-ctx-decrypt.c +226 -146
- data/ext/libmongocrypt/libmongocrypt/test/test-mongocrypt-ctx-encrypt.c +1330 -1200
- data/ext/libmongocrypt/libmongocrypt/test/test-mongocrypt-kek.c +1 -1
- data/ext/libmongocrypt/libmongocrypt/test/test-mongocrypt-key-cache.c +6 -6
- data/ext/libmongocrypt/libmongocrypt/test/test-mongocrypt-kms-responses.c +2 -2
- data/ext/libmongocrypt/libmongocrypt/test/test-mongocrypt-marking.c +744 -106
- data/ext/libmongocrypt/libmongocrypt/test/test-mongocrypt.c +119 -33
- data/ext/libmongocrypt/libmongocrypt/test/test-mongocrypt.h +27 -4
- data/ext/libmongocrypt/libmongocrypt/test/test-unicode-fold.c +97 -0
- data/lib/libmongocrypt_helper/version.rb +2 -2
- metadata +207 -157
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/README.md +0 -36
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/benchmarks/build.gradle.kts +0 -28
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/benchmarks/src/main/java/com/mongodb/crypt/benchmark/BenchmarkRunner.java +0 -217
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/benchmarks/src/main/resources/keyDocument.json +0 -24
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/build.gradle.kts +0 -354
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/gradle/wrapper/gradle-wrapper.jar +0 -0
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/gradle/wrapper/gradle-wrapper.properties +0 -5
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/gradlew +0 -234
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/gradlew.bat +0 -89
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/settings.gradle.kts +0 -1
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/main/java/com/mongodb/crypt/capi/BinaryHolder.java +0 -45
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/main/java/com/mongodb/crypt/capi/CAPI.java +0 -1165
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/main/java/com/mongodb/crypt/capi/CAPIHelper.java +0 -96
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/main/java/com/mongodb/crypt/capi/CipherCallback.java +0 -92
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/main/java/com/mongodb/crypt/capi/DisposableMemory.java +0 -31
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/main/java/com/mongodb/crypt/capi/JULLogger.java +0 -130
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/main/java/com/mongodb/crypt/capi/Logger.java +0 -144
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/main/java/com/mongodb/crypt/capi/Loggers.java +0 -50
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/main/java/com/mongodb/crypt/capi/MacCallback.java +0 -60
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/main/java/com/mongodb/crypt/capi/MessageDigestCallback.java +0 -55
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/main/java/com/mongodb/crypt/capi/MongoAwsKmsProviderOptions.java +0 -104
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/main/java/com/mongodb/crypt/capi/MongoCrypt.java +0 -100
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/main/java/com/mongodb/crypt/capi/MongoCryptContext.java +0 -137
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/main/java/com/mongodb/crypt/capi/MongoCryptContextImpl.java +0 -164
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/main/java/com/mongodb/crypt/capi/MongoCryptException.java +0 -67
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/main/java/com/mongodb/crypt/capi/MongoCryptImpl.java +0 -423
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/main/java/com/mongodb/crypt/capi/MongoCryptOptions.java +0 -284
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/main/java/com/mongodb/crypt/capi/MongoCrypts.java +0 -38
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/main/java/com/mongodb/crypt/capi/MongoDataKeyOptions.java +0 -125
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/main/java/com/mongodb/crypt/capi/MongoExplicitEncryptOptions.java +0 -227
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/main/java/com/mongodb/crypt/capi/MongoKeyDecryptor.java +0 -76
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/main/java/com/mongodb/crypt/capi/MongoKeyDecryptorImpl.java +0 -105
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/main/java/com/mongodb/crypt/capi/MongoLocalKmsProviderOptions.java +0 -83
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/main/java/com/mongodb/crypt/capi/MongoRewrapManyDataKeyOptions.java +0 -104
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/main/java/com/mongodb/crypt/capi/SLF4JLogger.java +0 -110
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/main/java/com/mongodb/crypt/capi/SecureRandomCallback.java +0 -51
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/main/java/com/mongodb/crypt/capi/SigningRSAESPKCSCallback.java +0 -76
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/main/java/com/mongodb/crypt/capi/package-info.java +0 -18
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/main/resources/META-INF/native-image/jni-config.json +0 -180
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/main/resources/META-INF/native-image/reflect-config.json +0 -134
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/test/java/com/mongodb/crypt/capi/MongoCryptTest.java +0 -389
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/test/resources/command-reply.json +0 -13
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/test/resources/command.json +0 -6
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/test/resources/encrypted-command-reply.json +0 -16
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/test/resources/encrypted-command.json +0 -11
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/test/resources/encrypted-value.json +0 -6
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/test/resources/fle2-find-range-explicit-v2/int32/encrypted-payload.json +0 -26
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/test/resources/fle2-find-range-explicit-v2/int32/key-filter.json +0 -19
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/test/resources/fle2-find-range-explicit-v2/int32/rangeopts.json +0 -14
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/test/resources/fle2-find-range-explicit-v2/int32/value-to-encrypt.json +0 -20
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/test/resources/json-schema.json +0 -15
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/test/resources/key-document.json +0 -36
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/test/resources/key-filter-keyAltName.json +0 -14
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/test/resources/key-filter.json +0 -19
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/test/resources/kms-reply.txt +0 -6
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/test/resources/list-collections-filter.json +0 -3
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/test/resources/mongocryptd-command.json +0 -22
- data/ext/libmongocrypt/libmongocrypt/bindings/java/mongocrypt/src/test/resources/mongocryptd-reply.json +0 -18
- data/ext/libmongocrypt/libmongocrypt/etc/silk-create-asset-group.sh +0 -70
- data/ext/libmongocrypt/libmongocrypt/test/data/bulkWrite/jsonSchema/cmd.json +0 -20
- data/ext/libmongocrypt/libmongocrypt/test/data/collection-info-no-schema.json +0 -19
- data/ext/libmongocrypt/libmongocrypt/test/data/compact/no-range/encrypted-field-config-map.json +0 -47
- data/ext/libmongocrypt/libmongocrypt/test/data/fle1-collMod/insert/cmd.json +0 -8
- data/ext/libmongocrypt/libmongocrypt/test/data/fle1-collMod/insert/collinfo.json +0 -9
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-create/ismaster-to-mongocryptd.json +0 -3
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-delete/empty/encrypted-payload.json +0 -91
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-delete/success/encrypted-payload.json +0 -98
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-explicit/find-indexed-contentionFactor1.json +0 -8
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-explicit/insert-indexed-contentionFactor1.json +0 -8
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-explicit/insert-indexed-same-user-and-index-key.json +0 -8
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-find-equality/cmd.json +0 -6
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-find-equality/encrypted-payload.json +0 -41
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-find-equality/mongocryptd-reply.json +0 -19
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-find-range/date/cmd.json +0 -10
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-find-range/date/encrypted-payload.json +0 -42
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-find-range/date/mongocryptd-reply.json +0 -50
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-find-range/decimal128/cmd.json +0 -6
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-find-range/decimal128/encrypted-field-map.json +0 -28
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-find-range/decimal128/encrypted-payload.json +0 -42
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-find-range/decimal128/mongocryptd-reply.json +0 -50
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-find-range/decimal128-precision/cmd.json +0 -6
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-find-range/decimal128-precision/encrypted-field-map.json +0 -31
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-find-range/decimal128-precision/encrypted-payload.json +0 -51
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-find-range/decimal128-precision/mongocryptd-reply.json +0 -59
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-find-range/double/cmd.json +0 -8
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-find-range/double/encrypted-payload.json +0 -42
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-find-range/double/mongocryptd-reply.json +0 -50
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-find-range/double-precision/cmd.json +0 -8
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-find-range/double-precision/encrypted-field-map.json +0 -31
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-find-range/double-precision/encrypted-payload.json +0 -45
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-find-range/double-precision/mongocryptd-reply.json +0 -53
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-find-range/int32/cmd.json +0 -8
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-find-range/int32/encrypted-payload.json +0 -42
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-find-range/int32/mongocryptd-reply.json +0 -50
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-find-range/int64/cmd.json +0 -8
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-find-range/int64/encrypted-field-map.json +0 -28
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-find-range/int64/encrypted-payload.json +0 -42
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-find-range/int64/mongocryptd-reply.json +0 -50
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-find-range-explicit/double/encrypted-payload.json +0 -26
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-find-range-explicit/double-precision/encrypted-payload.json +0 -26
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-find-range-explicit/int32/encrypted-payload.json +0 -26
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-find-range-explicit/int32-nominmax/encrypted-payload-v2.json +0 -26
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-find-range-explicit/int32-openinterval/encrypted-payload.json +0 -16
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-insert-range/date/cmd.json +0 -13
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-insert-range/date/encrypted-field-map.json +0 -28
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-insert-range/date/encrypted-payload.json +0 -45
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-insert-range/date/mongocryptd-reply.json +0 -53
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-insert-range/decimal128/cmd.json +0 -9
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-insert-range/decimal128/encrypted-field-map.json +0 -28
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-insert-range/decimal128/encrypted-payload.json +0 -45
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-insert-range/decimal128/mongocryptd-reply.json +0 -53
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-insert-range/decimal128-precision/cmd.json +0 -9
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-insert-range/decimal128-precision/encrypted-field-map.json +0 -31
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-insert-range/decimal128-precision/encrypted-payload.json +0 -54
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-insert-range/decimal128-precision/mongocryptd-reply.json +0 -62
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-insert-range/double/cmd.json +0 -11
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-insert-range/double/encrypted-field-map.json +0 -28
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-insert-range/double/encrypted-payload.json +0 -45
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-insert-range/double/mongocryptd-reply.json +0 -53
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-insert-range/double-precision/cmd.json +0 -11
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-insert-range/double-precision/encrypted-field-map.json +0 -31
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-insert-range/double-precision/encrypted-payload.json +0 -48
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-insert-range/double-precision/mongocryptd-reply.json +0 -56
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-insert-range/int32/encrypted-payload.json +0 -45
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-insert-range/int32/mongocryptd-reply.json +0 -53
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-insert-range/int64/cmd.json +0 -11
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-insert-range/int64/encrypted-field-map.json +0 -28
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-insert-range/int64/encrypted-payload.json +0 -45
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-insert-range/int64/mongocryptd-reply.json +0 -53
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-insert-range-explicit/double/encrypted-payload.json +0 -8
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-insert-range-explicit/double-precision/encrypted-payload.json +0 -8
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-insert-range-explicit/int32-nominmax/encrypted-payload-v2.json +0 -8
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-insert-range-explicit/sparsity-2/encrypted-payload.json +0 -8
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-insert-unindexed/cmd.json +0 -9
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-insert-unindexed/encrypted-payload.json +0 -14
- data/ext/libmongocrypt/libmongocrypt/test/data/fle2-insert-unindexed/mongocryptd-reply.json +0 -46
- data/ext/libmongocrypt/libmongocrypt/test/data/schema.json +0 -19
- /data/ext/libmongocrypt/libmongocrypt/test/data/{fle2-explicit/find-indexed.json → explicit-decrypt/FLE2FindEqualityPayload.json} +0 -0
- /data/ext/libmongocrypt/libmongocrypt/test/data/{fle2-insert → fle2-insert-text-search-with-str-encode-version}/cmd.json +0 -0
@@ -607,7 +607,7 @@ class TestMongoCryptCallback(unittest.TestCase):
|
|
607
607
|
encrypter = AutoEncrypter(callback, opts)
|
608
608
|
self.addCleanup(encrypter.close)
|
609
609
|
|
610
|
-
with respx.mock() as router:
|
610
|
+
with respx.mock(using="httpx") as router:
|
611
611
|
data = {"access_token": "foo"}
|
612
612
|
url = "http://metadata.google.internal/computeMetadata/v1/instance/service-accounts/default/token"
|
613
613
|
router.add(
|
@@ -748,7 +748,7 @@ if sys.version_info >= (3, 8, 0): # noqa: UP036
|
|
748
748
|
encrypter = AsyncAutoEncrypter(callback, opts)
|
749
749
|
self.addAsyncCleanup(encrypter.close)
|
750
750
|
|
751
|
-
with respx.mock() as router:
|
751
|
+
with respx.mock(using="httpx") as router:
|
752
752
|
data = {"access_token": "foo"}
|
753
753
|
url = "http://metadata.google.internal/computeMetadata/v1/instance/service-accounts/default/token"
|
754
754
|
router.add(
|
@@ -1019,7 +1019,7 @@ class TestNeedKMSAzureCredentials(unittest.TestCase):
|
|
1019
1019
|
|
1020
1020
|
def test_success(self):
|
1021
1021
|
encrypter = self.get_encrypter()
|
1022
|
-
with respx.mock() as router:
|
1022
|
+
with respx.mock(using="httpx") as router:
|
1023
1023
|
data = {"access_token": "foo", "expires_in": 4000}
|
1024
1024
|
url = "http://169.254.169.254/metadata/identity/oauth2/token"
|
1025
1025
|
router.add(
|
@@ -1034,7 +1034,7 @@ class TestNeedKMSAzureCredentials(unittest.TestCase):
|
|
1034
1034
|
|
1035
1035
|
def test_empty_json(self):
|
1036
1036
|
encrypter = self.get_encrypter()
|
1037
|
-
with respx.mock() as router:
|
1037
|
+
with respx.mock(using="httpx") as router:
|
1038
1038
|
url = "http://169.254.169.254/metadata/identity/oauth2/token"
|
1039
1039
|
router.add(
|
1040
1040
|
respx.get(url=url).mock(return_value=httpx.Response(200, json={}))
|
@@ -1048,7 +1048,7 @@ class TestNeedKMSAzureCredentials(unittest.TestCase):
|
|
1048
1048
|
|
1049
1049
|
def test_bad_json(self):
|
1050
1050
|
encrypter = self.get_encrypter()
|
1051
|
-
with respx.mock() as router:
|
1051
|
+
with respx.mock(using="httpx") as router:
|
1052
1052
|
url = "http://169.254.169.254/metadata/identity/oauth2/token"
|
1053
1053
|
router.add(
|
1054
1054
|
respx.get(url=url).mock(return_value=httpx.Response(200, text="a'"))
|
@@ -1062,7 +1062,7 @@ class TestNeedKMSAzureCredentials(unittest.TestCase):
|
|
1062
1062
|
|
1063
1063
|
def test_http_404(self):
|
1064
1064
|
encrypter = self.get_encrypter()
|
1065
|
-
with respx.mock() as router:
|
1065
|
+
with respx.mock(using="httpx") as router:
|
1066
1066
|
url = "http://169.254.169.254/metadata/identity/oauth2/token"
|
1067
1067
|
router.add(respx.get(url=url).mock(return_value=httpx.Response(404)))
|
1068
1068
|
with self.assertRaisesRegex(
|
@@ -1074,7 +1074,7 @@ class TestNeedKMSAzureCredentials(unittest.TestCase):
|
|
1074
1074
|
|
1075
1075
|
def test_http_500(self):
|
1076
1076
|
encrypter = self.get_encrypter()
|
1077
|
-
with respx.mock() as router:
|
1077
|
+
with respx.mock(using="httpx") as router:
|
1078
1078
|
url = "http://169.254.169.254/metadata/identity/oauth2/token"
|
1079
1079
|
router.add(respx.get(url=url).mock(return_value=httpx.Response(500)))
|
1080
1080
|
with self.assertRaisesRegex(
|
@@ -1086,7 +1086,7 @@ class TestNeedKMSAzureCredentials(unittest.TestCase):
|
|
1086
1086
|
|
1087
1087
|
def test_slow_response(self):
|
1088
1088
|
encrypter = self.get_encrypter()
|
1089
|
-
with respx.mock() as router:
|
1089
|
+
with respx.mock(using="httpx") as router:
|
1090
1090
|
url = "http://169.254.169.254/metadata/identity/oauth2/token"
|
1091
1091
|
router.add(
|
1092
1092
|
respx.get(url=url).mock(side_effect=httpx._exceptions.ConnectTimeout)
|
@@ -1100,7 +1100,7 @@ class TestNeedKMSAzureCredentials(unittest.TestCase):
|
|
1100
1100
|
|
1101
1101
|
def test_cache(self):
|
1102
1102
|
encrypter = self.get_encrypter()
|
1103
|
-
with respx.mock() as router:
|
1103
|
+
with respx.mock(using="httpx") as router:
|
1104
1104
|
data = {"access_token": "foo", "expires_in": 4000}
|
1105
1105
|
url = "http://169.254.169.254/metadata/identity/oauth2/token"
|
1106
1106
|
router.add(
|
@@ -1121,7 +1121,7 @@ class TestNeedKMSAzureCredentials(unittest.TestCase):
|
|
1121
1121
|
|
1122
1122
|
def test_cache_expires_soon(self):
|
1123
1123
|
encrypter = self.get_encrypter()
|
1124
|
-
with respx.mock() as router:
|
1124
|
+
with respx.mock(using="httpx") as router:
|
1125
1125
|
data = {"access_token": "foo", "expires_in": 10}
|
1126
1126
|
url = "http://169.254.169.254/metadata/identity/oauth2/token"
|
1127
1127
|
router.add(
|
@@ -1137,7 +1137,7 @@ class TestNeedKMSAzureCredentials(unittest.TestCase):
|
|
1137
1137
|
# Should not use the cached value.
|
1138
1138
|
encrypter = self.get_encrypter(False)
|
1139
1139
|
self.assertIsNotNone(pymongocrypt.synchronous.credentials._azure_creds_cache)
|
1140
|
-
with respx.mock() as router:
|
1140
|
+
with respx.mock(using="httpx") as router:
|
1141
1141
|
url = "http://169.254.169.254/metadata/identity/oauth2/token"
|
1142
1142
|
router.add(
|
1143
1143
|
respx.get(url=url).mock(side_effect=httpx._exceptions.ConnectTimeout)
|
@@ -1,8 +1,8 @@
|
|
1
1
|
include (FetchContent)
|
2
2
|
|
3
3
|
# Set the tag that we will fetch.
|
4
|
-
# When updating the version of libbson, also update the version in etc/purls.txt
|
5
|
-
set (MONGOC_FETCH_TAG_FOR_LIBBSON "1.
|
4
|
+
# When updating the version of libbson, also update the version in etc/purls.txt and .evergreen/prep_c_driver_source.sh
|
5
|
+
set (MONGOC_FETCH_TAG_FOR_LIBBSON "1.30.3" CACHE STRING "The Git tag of mongo-c-driver that will be fetched to obtain libbson")
|
6
6
|
|
7
7
|
# Add an option to disable patching if a patch command is unavailable.
|
8
8
|
option (LIBBSON_PATCH_ENABLED "Whether to apply patches to the libbson library" ON)
|
@@ -18,6 +18,8 @@ make_patch_command (patch_command
|
|
18
18
|
DISABLED "${patch_disabled}"
|
19
19
|
PATCHES
|
20
20
|
${PROJECT_SOURCE_DIR}/etc/libbson-remove-GCC-diagnostic-pragma.patch
|
21
|
+
# Fix old GCC error: "#pragma GCC diagnostic not allowed inside functions". Remove patch after libbson 2.0.0:
|
22
|
+
${PROJECT_SOURCE_DIR}/etc/libbson-remove-GCC-diagnostic-in-functions.patch
|
21
23
|
)
|
22
24
|
|
23
25
|
# Fetch the source archive for the requested tag from GitHub
|
@@ -56,9 +56,9 @@ cmake_push_check_state ()
|
|
56
56
|
# extra-alignment enabled. We want to match that setting as our default, for convenience
|
57
57
|
# purposes only.
|
58
58
|
find_path (SYSTEM_BSON_INCLUDE_DIR bson/bson.h PATH_SUFFIXES libbson-1.0)
|
59
|
+
set (_extra_alignment_default OFF)
|
59
60
|
if (SYSTEM_BSON_INCLUDE_DIR AND NOT DEFINED ENABLE_EXTRA_ALIGNMENT)
|
60
61
|
set (CMAKE_REQUIRED_INCLUDES "${SYSTEM_BSON_INCLUDE_DIR}")
|
61
|
-
set (_extra_alignment_default OFF)
|
62
62
|
check_c_source_compiles ([[
|
63
63
|
#include <bson/bson.h>
|
64
64
|
|
@@ -140,10 +140,8 @@ function (_import_bson)
|
|
140
140
|
set (ENABLE_SNAPPY OFF CACHE BOOL "Toggle snappy for the mongoc subproject (not required by libmongocrypt)")
|
141
141
|
# Disable deprecated automatic init and cleanup. (May be overridden by the user)
|
142
142
|
set (ENABLE_AUTOMATIC_INIT_AND_CLEANUP OFF CACHE BOOL "Enable automatic init and cleanup (GCC only)")
|
143
|
-
|
144
|
-
|
145
|
-
set (ENABLE_EXTRA_ALIGNMENT ${_extra_alignment_default} CACHE BOOL "Toggle extra alignment of bson_t")
|
146
|
-
endif ()
|
143
|
+
# Disable over-alignment of bson types. (May be overridden by the user)
|
144
|
+
set (ENABLE_EXTRA_ALIGNMENT ${_extra_alignment_default} CACHE BOOL "Toggle extra alignment of bson_t")
|
147
145
|
# We don't want the subproject to find libmongocrypt
|
148
146
|
set (ENABLE_CLIENT_SIDE_ENCRYPTION OFF CACHE BOOL "Disable client-side encryption for the libmongoc subproject")
|
149
147
|
# Clear `BUILD_VERSION` so C driver does not use a `BUILD_VERSION` meant for libmongocrypt.
|
@@ -44,18 +44,15 @@ snyk monitor \
|
|
44
44
|
|
45
45
|
Check the updated reference targets in Snyk for detected vulnerabilities.
|
46
46
|
|
47
|
-
#### Check
|
47
|
+
#### Check the Augmented SBOM
|
48
48
|
|
49
|
-
|
49
|
+
Examine the Augmented SBOM from a recent execution of the `sbom` task in an Evergreen patch or commit build.
|
50
|
+
|
51
|
+
Evergreen CLI may be used to schedule only the `sbom` task:
|
50
52
|
|
51
|
-
Download the Augmented SBOM using:
|
52
53
|
```bash
|
53
|
-
|
54
|
-
|
55
|
-
--secret silk_client_secret=${silk_client_secret} \
|
56
|
-
+sbom-download \
|
57
|
-
--out cyclonedx.augmented.sbom.json \
|
58
|
-
--branch <branch>
|
54
|
+
# Ensure `-p` matches the correct Evergreen project for the current branch!
|
55
|
+
evergreen patch -y -p libmongocrypt -t all -v sbom -f
|
59
56
|
```
|
60
57
|
|
61
58
|
Check the contents of the "vulnerabilities" field (if present) in the Augmented SBOM.
|
@@ -83,29 +80,16 @@ Do the following when releasing:
|
|
83
80
|
- If the `publish-packages` tasks fail with an error like `[curator] 2024/01/02 13:56:17 [p=emergency]: problem submitting repobuilder job: 404 (Not Found)`, this suggests the published path does not yet exist. Barque (the Linux package publishing service) has protection to avoid unintentional publishes. File a DEVPROD ticket ([example](https://jira.mongodb.org/browse/DEVPROD-4053)) and assign to the team called Release Infrastructure to request the path be created. Then re-run the failing `publish-packages` task. Ask in the slack channel `#devprod-release-tools` for further help with `Barque` or `curator`.
|
84
81
|
- Create the release from the GitHub releases page from the new tag.
|
85
82
|
- Attach the tarball and signature file from the Files tab of the `windows-upload-release` task. [Example](https://github.com/mongodb/libmongocrypt/releases/tag/1.10.0).
|
86
|
-
- Attach the Augmented SBOM file
|
87
|
-
|
88
|
-
./.evergreen/earthly.sh \
|
89
|
-
--secret silk_client_id=${silk_client_id} \
|
90
|
-
--secret silk_client_secret=${silk_client_secret} \
|
91
|
-
+sbom-download \
|
92
|
-
--out cyclonedx.augmented.sbom.json \
|
93
|
-
--branch <branch>
|
94
|
-
```
|
95
|
-
For a new minor release, use `master` for `--branch`. For a patch release, use the release branch (e.g. `rx.y`).
|
96
|
-
Secrets can be obtained from [AWS Secrets Manager](https://wiki.corp.mongodb.com/display/DRIVERS/Using+AWS+Secrets+Manager+to+Store+Testing+Secrets) under `drivers/libmongocrypt`.
|
83
|
+
- Attach the Augmented SBOM file to the release as `cyclonedx.augmented.sbom.json`.
|
84
|
+
Download the Augmented SBOM from a recent execution of the `sbom` task in an Evergreen patch or commit build.
|
97
85
|
- Attach `etc/third_party_vulnerabilities.md` to the release.
|
98
86
|
- Attach `etc/ssdlc_compliance_report.md` to the release.
|
99
87
|
|
100
88
|
- If this is a new minor release (e.g. `x.y.0`):
|
101
89
|
- File a DOCSP ticket to update the installation instructions on [Install libmongocrypt](https://www.mongodb.com/docs/manual/core/csfle/reference/libmongocrypt/). ([Example](https://jira.mongodb.org/browse/DOCSP-36863))
|
102
|
-
-
|
90
|
+
- Generate a new unique SBOM serial number for the next release:
|
103
91
|
```bash
|
104
|
-
./.evergreen/earthly.sh
|
105
|
-
--secret silk_client_id=${silk_client_id} \
|
106
|
-
--secret silk_client_secret=${silk_client_secret} \
|
107
|
-
+silk-create-asset-group \
|
108
|
-
--branch <branch>
|
92
|
+
./.evergreen/earthly.sh +sbom-generate-new-serial-number
|
109
93
|
```
|
110
94
|
- Create a new Snyk reference target. The following instructions use the example branch `rx.y`:
|
111
95
|
|
@@ -130,6 +114,10 @@ Do the following when releasing:
|
|
130
114
|
--remote-repo-url=https://github.com/mongodb/libmongocrypt.git
|
131
115
|
```
|
132
116
|
Snyk reference targets for older release branches may be removed if no further releases are expected on the branch.
|
117
|
+
- Update the [Github Webhook](https://wiki.corp.mongodb.com/display/INTX/Githook) to include the new branch.
|
118
|
+
- Navigate to the [Webhook Settings](https://github.com/mongodb/libmongocrypt/settings/hooks).
|
119
|
+
- Click `Edit` on the hook for `https://githook.mongodb.com/`.
|
120
|
+
- Add the new release branch to the `Payload URL`. Remove unmaintained release branches.
|
133
121
|
- Make a PR to apply the "Update CHANGELOG.md for x.y.z" commit to the `master` branch.
|
134
122
|
- Update the release on the [Jira releases page](https://jira.mongodb.org/projects/MONGOCRYPT/versions).
|
135
123
|
- Record the release on [C/C++ Release Info](https://docs.google.com/spreadsheets/d/1yHfGmDnbA5-Qt8FX4tKWC5xk9AhzYZx1SKF4AD36ecY/edit?usp=sharing). This is done to meet SSDLC reporting requirements.
|
@@ -160,4 +148,3 @@ index 609dc0b..f7530a9 100644
|
|
160
148
|
Architectures: amd64 arm64
|
161
149
|
suites:
|
162
150
|
```
|
163
|
-
|
@@ -1,16 +1,16 @@
|
|
1
1
|
{
|
2
2
|
"components": [
|
3
3
|
{
|
4
|
-
"bom-ref": "pkg:github/mongodb/mongo-c-driver@v1.
|
4
|
+
"bom-ref": "pkg:github/mongodb/mongo-c-driver@v1.30.3#src/libbson",
|
5
5
|
"copyright": "Copyright 2009-present MongoDB, Inc.",
|
6
6
|
"externalReferences": [
|
7
7
|
{
|
8
8
|
"type": "distribution",
|
9
|
-
"url": "https://github.com/mongodb/mongo-c-driver/archive/refs/tags/v1.
|
9
|
+
"url": "https://github.com/mongodb/mongo-c-driver/archive/refs/tags/v1.30.3.tar.gz"
|
10
10
|
},
|
11
11
|
{
|
12
12
|
"type": "website",
|
13
|
-
"url": "https://github.com/mongodb/mongo-c-driver/tree/v1.
|
13
|
+
"url": "https://github.com/mongodb/mongo-c-driver/tree/v1.30.3"
|
14
14
|
}
|
15
15
|
],
|
16
16
|
"group": "mongodb",
|
@@ -22,9 +22,9 @@
|
|
22
22
|
}
|
23
23
|
],
|
24
24
|
"name": "mongo-c-driver",
|
25
|
-
"purl": "pkg:github/mongodb/mongo-c-driver@v1.
|
25
|
+
"purl": "pkg:github/mongodb/mongo-c-driver@v1.30.3#src/libbson",
|
26
26
|
"type": "library",
|
27
|
-
"version": "v1.
|
27
|
+
"version": "v1.30.3"
|
28
28
|
},
|
29
29
|
{
|
30
30
|
"bom-ref": "pkg:generic/IntelRDFPMathLib@20U2?download_url=https://www.netlib.org/misc/intel/IntelRDFPMathLib20U2.tar.gz",
|
@@ -53,11 +53,11 @@
|
|
53
53
|
"ref": "pkg:generic/IntelRDFPMathLib@20U2?download_url=https://www.netlib.org/misc/intel/IntelRDFPMathLib20U2.tar.gz"
|
54
54
|
},
|
55
55
|
{
|
56
|
-
"ref": "pkg:github/mongodb/mongo-c-driver@v1.
|
56
|
+
"ref": "pkg:github/mongodb/mongo-c-driver@v1.30.3#src/libbson"
|
57
57
|
}
|
58
58
|
],
|
59
59
|
"metadata": {
|
60
|
-
"timestamp": "
|
60
|
+
"timestamp": "2025-04-08T13:06:37.750496+00:00",
|
61
61
|
"tools": [
|
62
62
|
{
|
63
63
|
"externalReferences": [
|
@@ -100,8 +100,8 @@
|
|
100
100
|
}
|
101
101
|
]
|
102
102
|
},
|
103
|
-
"serialNumber": "urn:uuid:
|
104
|
-
"version":
|
103
|
+
"serialNumber": "urn:uuid:1eeadd7e-be33-4e55-960c-02bac1da4cf7",
|
104
|
+
"version": 1,
|
105
105
|
"$schema": "http://cyclonedx.org/schema/bom-1.5.schema.json",
|
106
106
|
"bomFormat": "CycloneDX",
|
107
107
|
"specVersion": "1.5",
|
@@ -9,8 +9,6 @@ if ! run_python -c ''; then
|
|
9
9
|
fail "No Python found?"
|
10
10
|
fi
|
11
11
|
|
12
|
-
# Check that we have a pipx of the proper version:
|
13
|
-
run_python -c 'import pkg_resources; pkg_resources.require("pipx>=0.17.0,<2.0")'
|
14
12
|
|
15
13
|
# Give default clang-format an empty string on stdin if there are no inputs files
|
16
14
|
printf '' | run_python -m pipx run "clang-format==${CLANG_FORMAT_VERSION:?}" "$@"
|
@@ -0,0 +1,158 @@
|
|
1
|
+
diff --git a/src/libmongoc/src/mongoc/mongoc-collection.c b/src/libmongoc/src/mongoc/mongoc-collection.c
|
2
|
+
index d21a043788..ac0194e477 100644
|
3
|
+
--- a/src/libmongoc/src/mongoc/mongoc-collection.c
|
4
|
+
+++ b/src/libmongoc/src/mongoc/mongoc-collection.c
|
5
|
+
@@ -681,6 +681,7 @@ mongoc_collection_command_simple (mongoc_collection_t *collection,
|
6
|
+
*--------------------------------------------------------------------------
|
7
|
+
*/
|
8
|
+
|
9
|
+
+BEGIN_IGNORE_DEPRECATIONS
|
10
|
+
int64_t
|
11
|
+
mongoc_collection_count (mongoc_collection_t *collection, /* IN */
|
12
|
+
mongoc_query_flags_t flags, /* IN */
|
13
|
+
@@ -705,13 +706,12 @@ mongoc_collection_count (mongoc_collection_t *collection, /* IN */
|
14
|
+
/* Server Selection Spec: "may-use-secondary" commands SHOULD take a read
|
15
|
+
* preference argument and otherwise MUST use the default read preference
|
16
|
+
* from client, database or collection configuration. */
|
17
|
+
- BEGIN_IGNORE_DEPRECATIONS
|
18
|
+
ret = mongoc_collection_count_with_opts (collection, flags, query, skip, limit, &opts, read_prefs, error);
|
19
|
+
- END_IGNORE_DEPRECATIONS
|
20
|
+
|
21
|
+
bson_destroy (&opts);
|
22
|
+
return ret;
|
23
|
+
}
|
24
|
+
+END_IGNORE_DEPRECATIONS
|
25
|
+
|
26
|
+
|
27
|
+
int64_t
|
28
|
+
@@ -1231,6 +1231,7 @@ mongoc_collection_keys_to_index_string (const bson_t *keys)
|
29
|
+
}
|
30
|
+
|
31
|
+
|
32
|
+
+BEGIN_IGNORE_DEPRECATIONS
|
33
|
+
bool
|
34
|
+
mongoc_collection_create_index (mongoc_collection_t *collection,
|
35
|
+
const bson_t *keys,
|
36
|
+
@@ -1240,15 +1241,14 @@ mongoc_collection_create_index (mongoc_collection_t *collection,
|
37
|
+
bson_t reply;
|
38
|
+
bool ret;
|
39
|
+
|
40
|
+
- BEGIN_IGNORE_DEPRECATIONS
|
41
|
+
|
42
|
+
ret = mongoc_collection_create_index_with_opts (collection, keys, opt, NULL, &reply, error);
|
43
|
+
|
44
|
+
- END_IGNORE_DEPRECATIONS
|
45
|
+
|
46
|
+
bson_destroy (&reply);
|
47
|
+
return ret;
|
48
|
+
}
|
49
|
+
+END_IGNORE_DEPRECATIONS
|
50
|
+
|
51
|
+
static bool
|
52
|
+
_mongoc_collection_index_keys_equal (const bson_t *expected, const bson_t *actual)
|
53
|
+
@@ -1578,16 +1578,16 @@ done:
|
54
|
+
}
|
55
|
+
|
56
|
+
|
57
|
+
+BEGIN_IGNORE_DEPRECATIONS
|
58
|
+
bool
|
59
|
+
mongoc_collection_ensure_index (mongoc_collection_t *collection,
|
60
|
+
const bson_t *keys,
|
61
|
+
const mongoc_index_opt_t *opt,
|
62
|
+
bson_error_t *error)
|
63
|
+
{
|
64
|
+
- BEGIN_IGNORE_DEPRECATIONS
|
65
|
+
return mongoc_collection_create_index (collection, keys, opt, error);
|
66
|
+
- END_IGNORE_DEPRECATIONS
|
67
|
+
}
|
68
|
+
+END_IGNORE_DEPRECATIONS
|
69
|
+
|
70
|
+
|
71
|
+
mongoc_cursor_t *
|
72
|
+
@@ -2317,6 +2317,7 @@ mongoc_collection_replace_one (mongoc_collection_t *collection,
|
73
|
+
*--------------------------------------------------------------------------
|
74
|
+
*/
|
75
|
+
|
76
|
+
+BEGIN_IGNORE_DEPRECATIONS
|
77
|
+
bool
|
78
|
+
mongoc_collection_save (mongoc_collection_t *collection,
|
79
|
+
const bson_t *document,
|
80
|
+
@@ -2330,7 +2331,6 @@ mongoc_collection_save (mongoc_collection_t *collection,
|
81
|
+
BSON_ASSERT_PARAM (collection);
|
82
|
+
BSON_ASSERT_PARAM (document);
|
83
|
+
|
84
|
+
- BEGIN_IGNORE_DEPRECATIONS
|
85
|
+
if (!bson_iter_init_find (&iter, document, "_id")) {
|
86
|
+
return mongoc_collection_insert (collection, MONGOC_INSERT_NONE, document, write_concern, error);
|
87
|
+
}
|
88
|
+
@@ -2350,12 +2350,12 @@ mongoc_collection_save (mongoc_collection_t *collection,
|
89
|
+
|
90
|
+
ret = mongoc_collection_update (
|
91
|
+
collection, MONGOC_UPDATE_UPSERT | MONGOC_UPDATE_NO_VALIDATE, &selector, document, write_concern, error);
|
92
|
+
- END_IGNORE_DEPRECATIONS
|
93
|
+
|
94
|
+
bson_destroy (&selector);
|
95
|
+
|
96
|
+
return ret;
|
97
|
+
}
|
98
|
+
+END_IGNORE_DEPRECATIONS
|
99
|
+
|
100
|
+
|
101
|
+
bool
|
102
|
+
diff --git a/src/libmongoc/src/mongoc/mongoc-stream-tls.c b/src/libmongoc/src/mongoc/mongoc-stream-tls.c
|
103
|
+
index 744fdc4089..252d6209f3 100644
|
104
|
+
--- a/src/libmongoc/src/mongoc/mongoc-stream-tls.c
|
105
|
+
+++ b/src/libmongoc/src/mongoc/mongoc-stream-tls.c
|
106
|
+
@@ -187,6 +187,7 @@ mongoc_stream_tls_check_cert (mongoc_stream_t *stream, const char *host)
|
107
|
+
*--------------------------------------------------------------------------
|
108
|
+
*/
|
109
|
+
|
110
|
+
+BEGIN_IGNORE_DEPRECATIONS
|
111
|
+
mongoc_stream_t *
|
112
|
+
mongoc_stream_tls_new_with_hostname (mongoc_stream_t *base_stream, const char *host, mongoc_ssl_opt_t *opt, int client)
|
113
|
+
{
|
114
|
+
@@ -208,9 +209,7 @@ mongoc_stream_tls_new_with_hostname (mongoc_stream_t *base_stream, const char *h
|
115
|
+
#if defined(MONGOC_ENABLE_SSL_OPENSSL)
|
116
|
+
return mongoc_stream_tls_openssl_new (base_stream, host, opt, client);
|
117
|
+
#elif defined(MONGOC_ENABLE_SSL_LIBRESSL)
|
118
|
+
- BEGIN_IGNORE_DEPRECATIONS
|
119
|
+
return mongoc_stream_tls_libressl_new (base_stream, host, opt, client);
|
120
|
+
- END_IGNORE_DEPRECATIONS
|
121
|
+
#elif defined(MONGOC_ENABLE_SSL_SECURE_TRANSPORT)
|
122
|
+
return mongoc_stream_tls_secure_transport_new (base_stream, host, opt, client);
|
123
|
+
#elif defined(MONGOC_ENABLE_SSL_SECURE_CHANNEL)
|
124
|
+
@@ -219,6 +218,7 @@ mongoc_stream_tls_new_with_hostname (mongoc_stream_t *base_stream, const char *h
|
125
|
+
#error "Don't know how to create TLS stream"
|
126
|
+
#endif
|
127
|
+
}
|
128
|
+
+END_IGNORE_DEPRECATIONS
|
129
|
+
|
130
|
+
#if defined(MONGOC_ENABLE_SSL_OPENSSL) && OPENSSL_VERSION_NUMBER >= 0x10100000L
|
131
|
+
/*
|
132
|
+
diff --git a/src/libmongoc/src/mongoc/mongoc-write-concern.c b/src/libmongoc/src/mongoc/mongoc-write-concern.c
|
133
|
+
index 82ac8d3c32..10b8585c1c 100644
|
134
|
+
--- a/src/libmongoc/src/mongoc/mongoc-write-concern.c
|
135
|
+
+++ b/src/libmongoc/src/mongoc/mongoc-write-concern.c
|
136
|
+
@@ -492,6 +492,7 @@ mongoc_write_concern_append (mongoc_write_concern_t *write_concern, bson_t *comm
|
137
|
+
* Returns: A newly allocated mongoc_write_concern_t. This should be freed
|
138
|
+
* with mongoc_write_concern_destroy().
|
139
|
+
*/
|
140
|
+
+BEGIN_IGNORE_DEPRECATIONS
|
141
|
+
mongoc_write_concern_t *
|
142
|
+
_mongoc_write_concern_new_from_iter (const bson_iter_t *iter, bson_error_t *error)
|
143
|
+
{
|
144
|
+
@@ -532,9 +533,7 @@ _mongoc_write_concern_new_from_iter (const bson_iter_t *iter, bson_error_t *erro
|
145
|
+
if (!BSON_ITER_HOLDS_BOOL (&inner)) {
|
146
|
+
goto fail;
|
147
|
+
}
|
148
|
+
- BEGIN_IGNORE_DEPRECATIONS
|
149
|
+
mongoc_write_concern_set_fsync (write_concern, bson_iter_bool (&inner));
|
150
|
+
- END_IGNORE_DEPRECATIONS
|
151
|
+
} else if (BSON_ITER_IS_KEY (&inner, "j")) {
|
152
|
+
if (!BSON_ITER_HOLDS_BOOL (&inner)) {
|
153
|
+
goto fail;
|
154
|
+
@@ -560,3 +559,4 @@ fail:
|
155
|
+
mongoc_write_concern_destroy (write_concern);
|
156
|
+
return NULL;
|
157
|
+
}
|
158
|
+
+END_IGNORE_DEPRECATIONS
|
@@ -1,7 +1,7 @@
|
|
1
|
-
diff --git a/src/common/bson-dsl.h b/src/common/bson-dsl.h
|
1
|
+
diff --git a/src/common/src/common-bson-dsl-private.h b/src/common/src/common-bson-dsl-private.h
|
2
2
|
index 58a14e28e..3341e603f 100644
|
3
|
-
--- a/src/common/bson-dsl.h
|
4
|
-
+++ b/src/common/bson-dsl.h
|
3
|
+
--- a/src/common/src/common-bson-dsl-private.h
|
4
|
+
+++ b/src/common/src/common-bson-dsl-private.h
|
5
5
|
@@ -29,6 +29,13 @@ enum {
|
6
6
|
BSON_IF_WINDOWS (__declspec (selectany)) \
|
7
7
|
BSON_IF_POSIX (__attribute__ ((weak)))
|
@@ -8,7 +8,7 @@
|
|
8
8
|
# `copyright` property. This information can be manually added.
|
9
9
|
|
10
10
|
# libbson is obtained via `cmake/FetchMongoC.cmake`.
|
11
|
-
pkg:github/mongodb/mongo-c-driver@v1.
|
11
|
+
pkg:github/mongodb/mongo-c-driver@v1.30.3?#src/libbson
|
12
12
|
|
13
13
|
# IntelDFP is obtained via `cmake/IntelDFP.cmake`
|
14
14
|
pkg:generic/IntelRDFPMathLib@20U2?download_url=https://www.netlib.org/misc/intel/IntelRDFPMathLib20U2.tar.gz
|
@@ -9,6 +9,24 @@ There are two major parts to integrating libmongocrypt into your driver:
|
|
9
9
|
- Writing a language-specific binding to libmongocrypt
|
10
10
|
- Using the binding in your driver to support client side encryption
|
11
11
|
|
12
|
+
## Design Rationale
|
13
|
+
|
14
|
+
### Simple interface
|
15
|
+
|
16
|
+
The library interface is intended to be used with multiple languages.
|
17
|
+
|
18
|
+
The API tries to be minimal. Most structs are opaque. Global initialization
|
19
|
+
is lazy.
|
20
|
+
|
21
|
+
Much of the API passes and returns BSON since all drivers can produce and parse
|
22
|
+
BSON.
|
23
|
+
|
24
|
+
### No I/O
|
25
|
+
|
26
|
+
libmongocrypt deliberately does not do I/O to avoid poor behavior with some
|
27
|
+
language runtimes. Example: in Go a blocking C call may block an OS thread,
|
28
|
+
rather than a goroutine.
|
29
|
+
|
12
30
|
## Part 1: Writing a Language-Specific Binding ##
|
13
31
|
|
14
32
|
The binding is the glue between your driver\'s native language and
|
@@ -30,7 +48,7 @@ in the main public header
|
|
30
48
|
[mongocrypt.h](https://github.com/10gen/libmongocrypt/blob/master/src/mongocrypt.h).
|
31
49
|
|
32
50
|
There are many types and functions in mongocrypt.h to bind. Consider as
|
33
|
-
a first step binding to only `mongocrypt_version
|
51
|
+
a first step binding to only `mongocrypt_version`.
|
34
52
|
Once you have that working, proceed to write bindings for the remaining
|
35
53
|
API. Here are a few things to keep in mind:
|
36
54
|
|
@@ -122,6 +140,15 @@ All contexts.
|
|
122
140
|
|
123
141
|
#### State: `MONGOCRYPT_CTX_NEED_MONGO_COLLINFO` ####
|
124
142
|
|
143
|
+
> [!IMPORTANT]
|
144
|
+
> <a name="multi-collection-commands"></a> **Multi-collection commands**: prior to 1.13.0, drivers were expected to pass _at most one result_ from `listCollections`. In 1.13.0, drivers are expected to pass _all results_ from `listCollections` to support multi-collection commands (e.g. aggregate with `$lookup`).
|
145
|
+
>
|
146
|
+
> Drivers must call `mongocrypt_setopt_enable_multiple_collinfo` to indicate the new behavior is implemented and opt-in to support for multi-collection commands. This opt-in is to prevent the following bug scenario:
|
147
|
+
> > A driver upgrades to 1.13.0, but does not update prior behavior which passes at most one result of a multi-collection command.
|
148
|
+
> > A multi-collection command requests schemas for both `db.c1` and `db.c2`.
|
149
|
+
> > The driver only passes the result for `db.c1` even though `db.c2` also has a result.
|
150
|
+
> > Therefore, libmongocrypt incorrectly believes `db.c2` has no schema.
|
151
|
+
|
125
152
|
**libmongocrypt needs**...
|
126
153
|
|
127
154
|
A result from a listCollections cursor.
|
@@ -130,7 +157,7 @@ A result from a listCollections cursor.
|
|
130
157
|
|
131
158
|
1. Run listCollections on the encrypted MongoClient with the filter
|
132
159
|
provided by `mongocrypt_ctx_mongo_op`
|
133
|
-
2.
|
160
|
+
2. Pass all results (if any) with calls to `mongocrypt_ctx_mongo_feed` or proceed to the next step if nothing was returned. Results may be passed in any order.
|
134
161
|
3. Call `mongocrypt_ctx_mongo_done`
|
135
162
|
|
136
163
|
**Applies to...**
|
@@ -139,6 +166,8 @@ auto encrypt
|
|
139
166
|
|
140
167
|
#### State: `MONGOCRYPT_CTX_NEED_MONGO_COLLINFO_WITH_DB` ####
|
141
168
|
|
169
|
+
See [note](#multi-collection-commands) about multi-collection commands.
|
170
|
+
|
142
171
|
**libmongocrypt needs**...
|
143
172
|
|
144
173
|
Results from a listCollections cursor from a specified database.
|
@@ -147,7 +176,7 @@ Results from a listCollections cursor from a specified database.
|
|
147
176
|
|
148
177
|
1. Run listCollections on the encrypted MongoClient with the filter
|
149
178
|
provided by `mongocrypt_ctx_mongo_op` on the database provided by `mongocrypt_ctx_mongo_db`.
|
150
|
-
2.
|
179
|
+
2. Pass all results (if any) with calls to `mongocrypt_ctx_mongo_feed` or proceed to the next step if nothing was returned. Results may be passed in any order.
|
151
180
|
3. Call `mongocrypt_ctx_mongo_done`
|
152
181
|
|
153
182
|
**Applies to...**
|
@@ -195,13 +224,13 @@ All contexts except for create data key.
|
|
195
224
|
|
196
225
|
**libmongocrypt needs**...
|
197
226
|
|
198
|
-
The responses from one or more
|
227
|
+
The responses from one or more messages to KMS.
|
228
|
+
|
229
|
+
Ensure `mongocrypt_setopt_retry_kms` is called on the `mongocrypt_t` to enable retry.
|
199
230
|
|
200
231
|
**Driver needs to...**
|
201
232
|
|
202
|
-
1.
|
203
|
-
(Note, the driver MAY fan out all HTTP requests at the same time).
|
204
|
-
2. For each context:
|
233
|
+
1. For each context returned by `mongocrypt_ctx_next_kms_ctx`:
|
205
234
|
|
206
235
|
a. Delay the message by the time in microseconds indicated by
|
207
236
|
`mongocrypt_kms_ctx_usleep` if returned value is greater than 0.
|
@@ -219,11 +248,13 @@ The responses from one or more HTTP messages to KMS.
|
|
219
248
|
d. Feed the reply back with `mongocrypt_kms_ctx_feed`. Repeat
|
220
249
|
> until `mongocrypt_kms_ctx_bytes_needed` returns 0.
|
221
250
|
|
222
|
-
If any step encounters a network error,
|
223
|
-
`mongocrypt_kms_ctx_fail` returns true
|
224
|
-
error.
|
251
|
+
If any step encounters a network error, call `mongocrypt_kms_ctx_fail`.
|
252
|
+
If `mongocrypt_kms_ctx_fail` returns true, continue to the next KMS context.
|
253
|
+
If `mongocrypt_kms_ctx_fail` returns false, abort and report an error. Consider wrapping the error reported in `mongocrypt_kms_ctx_status` to include the last network error.
|
254
|
+
|
255
|
+
2. When done feeding all replies, call `mongocrypt_ctx_kms_done`.
|
225
256
|
|
226
|
-
|
257
|
+
Note, the driver MAY fan out KMS requests in parallel. More KMS requests may be added when processing responses to retry.
|
227
258
|
|
228
259
|
**Applies to...**
|
229
260
|
|
@@ -168,7 +168,7 @@ kms_sign_rsaes_pkcs1_v1_5 (void *unused_ctx,
|
|
168
168
|
|
169
169
|
success = CryptDecodeObjectEx (X509_ASN_ENCODING,
|
170
170
|
PKCS_PRIVATE_KEY_INFO,
|
171
|
-
private_key,
|
171
|
+
(BYTE*) private_key,
|
172
172
|
(DWORD) private_key_len,
|
173
173
|
0,
|
174
174
|
NULL,
|
@@ -182,7 +182,7 @@ kms_sign_rsaes_pkcs1_v1_5 (void *unused_ctx,
|
|
182
182
|
|
183
183
|
success = CryptDecodeObjectEx (X509_ASN_ENCODING,
|
184
184
|
PKCS_PRIVATE_KEY_INFO,
|
185
|
-
private_key,
|
185
|
+
(BYTE*) private_key,
|
186
186
|
(DWORD) private_key_len,
|
187
187
|
0,
|
188
188
|
NULL,
|
@@ -125,12 +125,12 @@ struct _kms_response_parser_t {
|
|
125
125
|
} while (0)
|
126
126
|
|
127
127
|
void
|
128
|
-
|
128
|
+
kms_set_error (char *error, size_t size, const char *fmt, ...);
|
129
129
|
|
130
130
|
#define KMS_ERROR(obj, ...) \
|
131
131
|
do { \
|
132
132
|
obj->failed = true; \
|
133
|
-
|
133
|
+
kms_set_error (obj->error, sizeof (obj->error), __VA_ARGS__); \
|
134
134
|
} while (0)
|
135
135
|
|
136
136
|
#define KMS_ASSERT(stmt) \
|
@@ -789,7 +789,7 @@ kms_request_get_signed (kms_request_t *request)
|
|
789
789
|
}
|
790
790
|
|
791
791
|
if (!check_and_prohibit_kmip (request)) {
|
792
|
-
return
|
792
|
+
return NULL;
|
793
793
|
}
|
794
794
|
|
795
795
|
if (!finalize (request)) {
|
@@ -857,11 +857,11 @@ kms_request_to_string (kms_request_t *request)
|
|
857
857
|
size_t i;
|
858
858
|
|
859
859
|
if (!finalize (request)) {
|
860
|
-
return
|
860
|
+
return NULL;
|
861
861
|
}
|
862
862
|
|
863
863
|
if (!check_and_prohibit_kmip (request)) {
|
864
|
-
return
|
864
|
+
return NULL;
|
865
865
|
}
|
866
866
|
|
867
867
|
if (request->to_string) {
|