]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
net: ipv4: Use kfree_sensitive instead of kfree
authorWang Ming <machel@vivo.com>
Mon, 17 Jul 2023 09:59:19 +0000 (17:59 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 27 Jul 2023 06:47:01 +0000 (08:47 +0200)
commitb87a7e3a330caabea48d6120bb58b430ee8f9fdd
treed89478791777cf8bc8db0fbb8a9683714bc3aaee
parent5dd4d1ff8ba1145fa0a58af6a031541ccbc9f745
net: ipv4: Use kfree_sensitive instead of kfree

[ Upstream commit daa751444fd9d4184270b1479d8af49aaf1a1ee6 ]

key might contain private part of the key, so better use
kfree_sensitive to free it.

Fixes: 38320c70d282 ("[IPSEC]: Use crypto_aead and authenc in ESP")
Signed-off-by: Wang Ming <machel@vivo.com>
Reviewed-by: Tariq Toukan <tariqt@nvidia.com>
Reviewed-by: Kuniyuki Iwashima <kuniyu@amazon.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Sasha Levin <sashal@kernel.org>
net/ipv4/esp4.c