Commit 0325e57e authored by Mimi Zohar's avatar Mimi Zohar Committed by Yang Yingliang
Browse files

evm: fix writing <securityfs>/evm overflow



stable inclusion
from linux-4.19.198
commit 8657d0d57d6df9d6d04277c18889da2804164ca3

--------------------------------

[ Upstream commit 49219d9b ]

EVM_SETUP_COMPLETE is defined as 0x80000000, which is larger than INT_MAX.
The "-fno-strict-overflow" compiler option properly prevents signaling
EVM that the EVM policy setup is complete.  Define and read an unsigned
int.

Fixes: f00d7975 ("EVM: Allow userspace to signal an RSA key has been loaded")
Signed-off-by: default avatarMimi Zohar <zohar@linux.ibm.com>
Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
Signed-off-by: default avatarYang Yingliang <yangyingliang@huawei.com>
parent 00a695ca
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment