[PATCH] KEYS: Use kfree_sensitive() in keyctl_pkey_e_d_s()
sashiko-bot at kernel.org
sashiko-bot at kernel.org
Tue Nov 24 05:34:11 UTC 2026
> keyctl_pkey_e_d_s() frees the temporary 'in' and 'out' buffers with
> kfree(). For encrypt, decrypt and sign operations these buffers hold
> plaintext or other sensitive data.
>
> Free them with kfree_sensitive() instead.
>
> Closes: https://sashiko.dev/#/bug/linux-4199b169-0b8d-4055-9a71-6b5b79e38eb3
> Fixes: 00d60fd3b932 ("KEYS: Provide keyctls to drive the new key type ops for asymmetric keys [ver #2]")
> Cc: stable at vger.kernel.org
> Signed-off-by: Guicai Ma <maguicai at kylinos.cn>
Sashiko has reviewed this patch and found no issues.
--
Sashiko AI review · https://sashiko.dev/#/patchset/20261124052849.940005-1-maguicai@kylinos.cn?part=1
More information about the Linux-security-module-archive
mailing list