Provided by: libmongoc-doc_2.2.1-1_all 

SYNOPSIS
bool
mongoc_client_encryption_decrypt (mongoc_client_encryption_t *client_encryption,
const bson_value_t *ciphertext,
bson_value_t *value,
bson_error_t *error);
Performs explicit decryption.
value is always initialized (even on failure). Caller must call bson_value_destroy() <https://www.mongoc
.org/libbson/current/bson_value_destroy.html> to free.
PARAMETERS
• client_encryption: A mongoc_client_encryption_t <>
• ciphertext: The ciphertext (a BSON binary with subtype 6) to decrypt.
• value: A bson_value_t <https://www.mongoc.org/libbson/current/bson_value_t.html> for the resulting
decrypted value.
• 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_enable_auto_encryption() <>
mongoc_client_encryption_encrypt() <>
Author
MongoDB, Inc
Copyright
2009-present, MongoDB, Inc.
2.2.1 Dec 11, 2025 MONGOC_CLIENT_DECRYPTION_DECRYPT(3)