Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow empty password #4698

Closed
wants to merge 3 commits into from
Closed

Allow empty password #4698

wants to merge 3 commits into from

Commits on Feb 12, 2024

  1. Support to use an empty password if really desired

    Subcommands `init` and `key add|passwd` now support the flag
    `--insecure-password` which disables the check for an empty password.
    `restic` warns about it, though.
    Support for `RESTIC_PASSWORD_FILE` and coresponding CLI option has been
    added as well. You may user either an empty file or just `/dev/null`.
    
    Basic support for Bash completion is there. But I am unsure if I got the
    semantic right. Haven't done something like this before. It lacks
    support for other shells.
    
    Internal the empty password is represented by an arbitrary, non-valid
    UTF-8 byte sequence (`0xff`) to allow to distinguish between not yet
    loaded and empty password.
    See https://stackoverflow.com/a/30741287.
    
    This is just a PoC, I haven't ever written a single Go line before.
    doak committed Feb 12, 2024
    Configuration menu
    Copy the full SHA
    060d8ee View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    66e7b0f View commit details
    Browse the repository at this point in the history
  3. squash! Support to use an empty password if really desired

    Support to use an empty password if really desired
    
    Subcommands `init` and `key add|passwd` now support the flag
    `--allow-empty-password` which disables the check for an empty password.
    `restic` warns about it, though.
    Support for `RESTIC_PASSWORD_FILE` and coresponding CLI option has been
    added as well. You may user either an empty file or just `/dev/null`.
    
    Basic support for Bash completion is there. But I am unsure if I got the
    semantic right. Haven't done something like this before. It lacks
    support for other shells.
    
    Internal the empty password is represented by an arbitrary, non-valid
    UTF-8 byte sequence (`0xff`) to allow to distinguish between not yet
    loaded and empty password.
    See https://stackoverflow.com/a/30741287.
    
    This is just a PoC, I haven't ever written a single Go line before.
    doak committed Feb 12, 2024
    Configuration menu
    Copy the full SHA
    92d1c11 View commit details
    Browse the repository at this point in the history