Skip to content

Commit 861261f

Browse files
committed
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/[email protected] Signed-off-by: Eric Biggers <[email protected]>
1 parent ee446e1 commit 861261f

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

fs/ubifs/ioctl.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -208,6 +208,9 @@ long ubifs_ioctl(struct file *file, unsigned int cmd, unsigned long arg)
208208
case FS_IOC_GET_ENCRYPTION_KEY_STATUS:
209209
return fscrypt_ioctl_get_key_status(file, (void __user *)arg);
210210

211+
case FS_IOC_GET_ENCRYPTION_NONCE:
212+
return fscrypt_ioctl_get_nonce(file, (void __user *)arg);
213+
211214
default:
212215
return -ENOTTY;
213216
}
@@ -230,6 +233,7 @@ long ubifs_compat_ioctl(struct file *file, unsigned int cmd, unsigned long arg)
230233
case FS_IOC_REMOVE_ENCRYPTION_KEY:
231234
case FS_IOC_REMOVE_ENCRYPTION_KEY_ALL_USERS:
232235
case FS_IOC_GET_ENCRYPTION_KEY_STATUS:
236+
case FS_IOC_GET_ENCRYPTION_NONCE:
233237
break;
234238
default:
235239
return -ENOIOCTLCMD;

0 commit comments

Comments
 (0)