1
0
Fork 0
mirror of https://github.com/borgbackup/borg.git synced 2025-02-25 07:23:28 +00:00

init: add warning to store both key and passphrase at safe place(s)

(cherry picked from commit 4b31ad123f)
This commit is contained in:
Thomas Waldmann 2018-08-09 07:20:44 +02:00
parent 64f2fc0a65
commit d21da08f85

View file

@ -286,6 +286,13 @@ def do_init(self, args, repository):
'\n'
'See https://borgbackup.readthedocs.io/en/stable/changes.html#pre-1-0-9-manifest-spoofing-vulnerability '
'for details about the security implications.', shlex.quote(path))
if key.NAME != 'plaintext':
logger.warning(
'\n'
'IMPORTANT: you will need both KEY AND PASSPHRASE to access this repo!\n'
'Use "borg key export" to export the key, optionally in printable format.\n'
'Write down the passphrase. Store both at safe place(s).\n')
return self.exit_code
@with_repository(exclusive=True, manifest=False)