Provided by: libmongoc-doc_2.2.0-1_all 

SYNOPSIS
bool
mongoc_client_encryption_rewrap_many_datakey (
mongoc_client_encryption_t *client_encryption,
const bson_t *filter,
const char *provider,
const bson_t *master_key,
mongoc_client_encryption_rewrap_many_datakey_result_t *result,
bson_error_t *error);
Rewraps zero or more data keys in the key vault collection that match the provided filter.
A NULL argument for filter is equivalent to being given an empty document (match all).
If provider is NULL, rewraps matching data keys with their current KMS provider and master key.
If provider is not NULL, rewraps matching data keys with the new KMS provider as described by master_key.
The master_key document must conform to the Client Side Encryption specification <https://github.com/
mongodb/specifications/blob/master/source/client-side-encryption/client-side-encryption.md#masterkey>.
PARAMETERS
• client_encryption: A mongoc_client_encryption_t <>.
• filter: The filter to use when finding data keys to rewrap in the key vault collection.
• provider: The new KMS provider to use to encrypt the data keys, or NULL to use the current KMS
provider(s).
• master_key: The master key fields corresponding to the new KMS provider when provider is not NULL.
• result: An optional mongoc_client_encryption_rewrap_many_datakey_result_t <>.
• error: A bson_error_t <https://www.mongoc.org/libbson/current/bson_error_t.html> set on failure.
RETURNS
Returns true if successful. Returns false and sets error otherwise.
See also:
mongoc_client_encryption_rewrap_many_datakey_result_t <>
Author
MongoDB, Inc
Copyright
2009-present, MongoDB, Inc.
2.2.0 Nov 26, 2025 MONGOC_CLIENT_ENCRYPTION_REWRAP_MANY_DATAKEY(3)