diff options
| author | Eric Biggers <ebiggers@google.com> | 2022-01-18 21:11:01 -0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2022-01-18 21:11:01 -0800 |
| commit | fac30865c04de8f4698776e94dd86c7a88fd5da2 (patch) | |
| tree | 58d70d8ded0c14baeec01e0db1991385419a376c /cli-tests/t_encrypt_login.sh | |
| parent | 7813af71eba05166e0c2f7056e094ca8756fbe8e (diff) | |
| parent | 5ae7da4ee6582099de5d1b14733f8d58f4dc2816 (diff) | |
Merge pull request #337 from google/broken-links
filesystem: store mountpoint in link files as a fallback
Diffstat (limited to 'cli-tests/t_encrypt_login.sh')
| -rwxr-xr-x | cli-tests/t_encrypt_login.sh | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/cli-tests/t_encrypt_login.sh b/cli-tests/t_encrypt_login.sh index c42fec7..5085068 100755 --- a/cli-tests/t_encrypt_login.sh +++ b/cli-tests/t_encrypt_login.sh @@ -86,3 +86,11 @@ chown "$TEST_USER" "$dir" _user_do_and_expect_failure \ "echo wrong_passphrase | fscrypt encrypt --quiet --source=pam_passphrase '$dir'" show_status false + +begin "Test that linked protector works even if UUID link is broken" +echo TEST_USER_PASS | fscrypt encrypt --quiet --source=pam_passphrase --user="$TEST_USER" "$dir" +protector=$(get_login_protector) +link_file=$MNT/.fscrypt/protectors/$protector.link +[ -e "$link_file" ] || _fail "$link_file does not exist" +sed -i 's/UUID=.*/UUID=00000000-0000-0000-0000-000000000000/' "$link_file" +fscrypt status "$MNT" |