diff options
author | Eric Biggers <ebiggers@google.com> | 2020-03-14 23:50:52 +0300 |
---|---|---|
committer | Eric Biggers <ebiggers@google.com> | 2020-03-20 07:57:06 +0300 |
commit | 861261f2a9cc488c845fc214d9035f7a11094591 (patch) | |
tree | 3fdd1c668bc9e3e77528b4e795f7af8d72f0de63 /fs/ubifs | |
parent | ee446e1af4ff90945e2273ae0af322b8b745b8cc (diff) | |
download | linux-861261f2a9cc488c845fc214d9035f7a11094591.tar.xz |
ubifs: wire up FS_IOC_GET_ENCRYPTION_NONCE
This new ioctl retrieves a file's encryption nonce, which is useful for
testing. See the corresponding fs/crypto/ patch for more details.
Link: https://lore.kernel.org/r/20200314205052.93294-5-ebiggers@kernel.org
Signed-off-by: Eric Biggers <ebiggers@google.com>
Diffstat (limited to 'fs/ubifs')
-rw-r--r-- | fs/ubifs/ioctl.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/fs/ubifs/ioctl.c b/fs/ubifs/ioctl.c index d49fc04f2d7d..3df9be2c684c 100644 --- a/fs/ubifs/ioctl.c +++ b/fs/ubifs/ioctl.c @@ -208,6 +208,9 @@ long ubifs_ioctl(struct file *file, unsigned int cmd, unsigned long arg) case FS_IOC_GET_ENCRYPTION_KEY_STATUS: return fscrypt_ioctl_get_key_status(file, (void __user *)arg); + case FS_IOC_GET_ENCRYPTION_NONCE: + return fscrypt_ioctl_get_nonce(file, (void __user *)arg); + default: return -ENOTTY; } @@ -230,6 +233,7 @@ long ubifs_compat_ioctl(struct file *file, unsigned int cmd, unsigned long arg) case FS_IOC_REMOVE_ENCRYPTION_KEY: case FS_IOC_REMOVE_ENCRYPTION_KEY_ALL_USERS: case FS_IOC_GET_ENCRYPTION_KEY_STATUS: + case FS_IOC_GET_ENCRYPTION_NONCE: break; default: return -ENOIOCTLCMD; |