Method: Mongo::ClientEncryption#delete_key

Defined in:
lib/mongo/client_encryption.rb

#delete_key(id) ⇒ Operation::Result

Removes the key with the given id from the key vault collection.

Parameters:

  • id (BSON::Binary)

    Id of the key to delete.

Returns:

  • (Operation::Result)

    The response from the database for the delete_one operation that deletes the key.



193
194
195
# File 'lib/mongo/client_encryption.rb', line 193

def delete_key(id)
  @encrypter.delete_key(id)
end