diff --git a/fscryptctl.c b/fscryptctl.c index c26785a..a1798e1 100644 --- a/fscryptctl.c +++ b/fscryptctl.c @@ -598,6 +598,11 @@ static void show_v2_encryption_policy(const struct fscrypt_policy_v2 *policy) { show_encryption_mode(policy->contents_encryption_mode, "Contents"); show_encryption_mode(policy->filenames_encryption_mode, "Filenames"); show_policy_flags(policy->flags); + if (policy->log2_data_unit_size) { + printf("\tData unit size: %u\n", 1U << policy->log2_data_unit_size); + } else { + printf("\tData unit size: default\n"); + } } // For a specified file or directory with encryption enabled, print the diff --git a/test.py b/test.py index 2ae922d..9111cf1 100644 --- a/test.py +++ b/test.py @@ -149,7 +149,8 @@ def describe_policy(path=TEST_DIR, key=TEST_KEY, contents="AES-256-XTS", out += "\tMaster key identifier: {}\n".format(key["identifier"]) out += "\tContents encryption mode: {}\n".format(contents) out += "\tFilenames encryption mode: {}\n".format(filenames) - out += "\tFlags: {}".format(flags) + out += "\tFlags: {}\n".format(flags) + out += "\tData unit size: default" return out