aboutsummaryrefslogtreecommitdiff
path: root/net/tls
diff options
context:
space:
mode:
authorZheng Wang2022-11-10 11:50:33 +0800
committerGreg Kroah-Hartman2022-12-31 13:32:40 +0100
commit4e947fc71bec7c7da791f8562d5da233b235ba5e (patch)
tree96c3e04b538b7143952b609bfc702d2eb1f99406 /net/tls
parentef843ee20576039126d34d6eb5f45d14c3e6ce18 (diff)
misc: sgi-gru: fix use-after-free error in gru_set_context_option, gru_fault and gru_handle_user_call_os
[ Upstream commit 643a16a0eb1d6ac23744bb6e90a00fc21148a9dc ] In some bad situation, the gts may be freed gru_check_chiplet_assignment. The call chain can be gru_unload_context->gru_free_gru_context->gts_drop and kfree finally. However, the caller didn't know if the gts is freed or not and use it afterwards. This will trigger a Use after Free bug. Fix it by introducing a return value to see if it's in error path or not. Free the gts in caller if gru_check_chiplet_assignment check failed. Fixes: 55484c45dbec ("gru: allow users to specify gru chiplet 2") Signed-off-by: Zheng Wang <zyytlz.wz@163.com> Acked-by: Dimitri Sivanich <sivanich@hpe.com> Link: https://lore.kernel.org/r/20221110035033.19498-1-zyytlz.wz@163.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'net/tls')
0 files changed, 0 insertions, 0 deletions