MCPcopy
hub / github.com/borgbackup/borg / assert_secure

Method assert_secure

src/borg/cache.py:193–198  ·  view source on GitHub ↗
(self, manifest, key, *, warn_if_unencrypted=True)

Source from the content-addressed store, hash-verified

191 raise Cache.EncryptionMethodMismatch()
192
193 def assert_secure(self, manifest, key, *, warn_if_unencrypted=True):
194 # warn_if_unencrypted=False is only used for initializing a new repository.
195 # Thus, avoiding asking about a repository that's currently initializing.
196 self.assert_access_unknown(warn_if_unencrypted, manifest, key)
197 self._assert_secure(manifest, key)
198 logger.debug("security: repository checks ok, allowing access")
199
200 def _assert_secure(self, manifest, key):
201 self.assert_location_matches()

Callers 2

assert_secureFunction · 0.95
__init__Method · 0.80

Calls 3

assert_access_unknownMethod · 0.95
_assert_secureMethod · 0.95
debugMethod · 0.80

Tested by

no test coverage detected