generic: test validation of encryption policy structure

Add an xfstest which verifies the kernel performs basic validation
of the encryption policy structure.

Signed-off-by: Eric Biggers <ebiggers@google.com>
Reviewed-by: Eryu Guan <eguan@redhat.com>
Signed-off-by: Eryu Guan <eguan@redhat.com>
This commit is contained in:
Eric Biggers
2016-12-15 12:26:22 -08:00
committed by Eryu Guan
parent b8f280fcdb
commit 88d1c426f4
3 changed files with 101 additions and 0 deletions
+18
View File
@@ -0,0 +1,18 @@
QA output created by 396
*** Invalid contents encryption mode ***
SCRATCH_MNT/dir: failed to set encryption policy: Invalid argument
*** Invalid filenames encryption mode ***
SCRATCH_MNT/dir: failed to set encryption policy: Invalid argument
*** Invalid flags ***
SCRATCH_MNT/dir: failed to set encryption policy: Invalid argument
*** Invalid policy version ***
SCRATCH_MNT/dir: failed to set encryption policy: Invalid argument
*** Invalid combinations of modes ***
SCRATCH_MNT/dir: failed to set encryption policy: Invalid argument
SCRATCH_MNT/dir: failed to set encryption policy: Invalid argument
SCRATCH_MNT/dir: failed to set encryption policy: Invalid argument