Skip to content

Commit

Permalink
fscrypt: print debug message for FSCRYPT v1 devices
Browse files Browse the repository at this point in the history
Change-Id: I26b8681272c1083e3c484e32a6b74a17f1c1f821
  • Loading branch information
bigbiff authored and epicX67 committed Nov 4, 2021
1 parent 805c5b7 commit b19632e
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions libtar/append.c
Original file line number Diff line number Diff line change
Expand Up @@ -172,6 +172,7 @@ tar_append_file(TAR *t, const char *realname, const char *savename)
|| strncmp((char *) tar_policy, SYSTEM_DE_FSCRYPT_POLICY, sizeof(SYSTEM_DE_FSCRYPT_POLICY)) == 0) {
#ifdef USE_FSCRYPT_POLICY_V1
memcpy(t->th_buf.fep->master_key_descriptor, tar_policy, FS_KEY_DESCRIPTOR_SIZE);
printf("found fscrypt policy '%s' - '%s' - '%s'\n", realname, t->th_buf.fep->master_key_descriptor, policy_hex);
#else
memcpy(t->th_buf.fep->master_key_identifier, tar_policy, FSCRYPT_KEY_IDENTIFIER_SIZE);
printf("found fscrypt policy '%s' - '%s' - '%s'\n", realname, t->th_buf.fep->master_key_identifier, policy_hex);
Expand Down

0 comments on commit b19632e

Please sign in to comment.