MCPcopy Index your code
hub / github.com/mongodb/mongo-python-driver / fetch_keys

Method fetch_keys

pymongo/asynchronous/encryption.py:307–317  ·  view source on GitHub ↗

Yields one or more keys from the key vault. :param filter: The filter to pass to find. :return: A generator which yields the requested keys from the key vault.

(self, filter: bytes)

Source from the content-addressed store, hash-verified

305 return res.raw
306
307 async def fetch_keys(self, filter: bytes) -> AsyncGenerator[bytes | memoryview, None]:
308 """Yields one or more keys from the key vault.
309
310 :param filter: The filter to pass to find.
311
312 :return: A generator which yields the requested keys from the key vault.
313 """
314 assert self.key_vault_coll is not None
315 async with self.key_vault_coll.find(RawBSONDocument(filter)) as cursor:
316 async for key in cursor:
317 yield key.raw
318
319 async def insert_data_key(self, data_key: bytes) -> Binary:
320 """Insert a data key into the key vault.

Callers

nothing calls this directly

Calls 2

RawBSONDocumentClass · 0.90
findMethod · 0.45

Tested by

no test coverage detected