diff options
| author | Eric Biggers <ebiggers@google.com> | 2020-05-09 14:04:47 -0700 |
|---|---|---|
| committer | Eric Biggers <ebiggers@google.com> | 2020-05-09 14:04:47 -0700 |
| commit | 8ff53630f1cc90ae23835e9571f9096e211dce67 (patch) | |
| tree | 56eaebbb984ff3e4e2f8512e17bff3be77fe4bb0 /actions/protector.go | |
| parent | 31bc8c843e1862b2d28f31eff85eca3d1dbd4754 (diff) | |
cmd/fscrypt: add FSCRYPT_ROOT_MNT environmental variable
Allow overriding the mountpoint where login protectors are stored by
setting the FSCRYPT_ROOT_MNT environmental variable. The CLI tests need
this to avoid touching the real "/".
Diffstat (limited to 'actions/protector.go')
| -rw-r--r-- | actions/protector.go | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/actions/protector.go b/actions/protector.go index 4bd7c15..dab9c27 100644 --- a/actions/protector.go +++ b/actions/protector.go @@ -30,6 +30,10 @@ import ( "github.com/google/fscrypt/util" ) +// LoginProtectorMountpoint is the mountpoint where login protectors are stored. +// This can be overridden by the user of this package. +var LoginProtectorMountpoint = "/" + // Errors relating to Protectors var ( ErrProtectorName = errors.New("login protectors do not need a name") |