Client-Side Field Level Encryption Methods客户端字段级加密方法
For details on a specific method, including syntax and examples, click on the link to the method's reference page.有关特定方法的详细信息,包括语法和示例,请单击该方法参考页的链接。
The mongosh
client-side field level encryption methods require a database connection with client-side field level encryption enabled. mongosh
客户端字段级加密方法需要启用客户端字段级密码的数据库连接。If the current database connection was not initiated with client-side field level encryption enabled, either:如果当前数据库连接未在启用客户端字段级加密的情况下启动,请执行以下任一操作:
Use the使用Mongo()
constructor from themongosh
to establish a connection with the required client-side field level encryption options.mongosh
中的Mongo()
构造函数与所需的客户端字段级加密选项建立连接。TheMongo()
method supports the following Key Management Service (KMS) providers for Customer Master Key (CMK) management:Mongo()
方法支持以下用于客户主键(CMK)管理的键管理服务(KMS)提供程序:Amazon Web Services KMS亚马逊网络服务KMSAzure Key VaultAzure键保管库Google Cloud Platform KMS谷歌云平台KMSLocally Managed Key本地管理键
or
Use the使用mongosh
command line options to establish a connection with the required options.mongosh
命令行选项可以建立与所需选项的连接。The command line options only support the Amazon Web Services KMS provider for CMK management.命令行选项仅支持用于CMK管理的Amazon Web Services KMS提供程序。
The following methods are for 以下方法仅适用于mongosh
only. For instructions on implementing client-side field level encryption using a MongoDB 4.2+ compatible driver, defer to the driver documentation. mongosh
。有关使用MongoDB 4.2+兼容驱动程序实现客户端字段级加密的说明,请参阅驱动程序文档。See CSFLE Compatibility for a complete list of 4.2+ compatible drivers with support for client-side field level encryption.有关支持客户端字段级加密的4.2+兼容驱动程序的完整列表,请参阅CSFLE兼容性。
getKeyVault() | |
KeyVault.createKey() | |
KeyVault.deleteKey() | |
KeyVault.getKey() | |
KeyVault.getKeys() | |
KeyVault.addKeyAlternateName() | |
KeyVault.removeKeyAlternateName() | |
KeyVault.rewrapManyDataKey() | |
KeyVault.getKeyByAltName() | |
getClientEncryption() | |
ClientEncryption.createEncryptedCollection() | |
ClientEncryption.encrypt() | |
ClientEncryption.decrypt() |