linux-stable/drivers/target
Maurizio Lombardi 63e8706d12 scsi: iscsi: set auth_protocol back to NULL if CHAP_A value is not supported
[ Upstream commit 5dd6c49339 ]

If the CHAP_A value is not supported, the chap_server_open() function
should free the auth_protocol pointer and set it to NULL, or we will leave
a dangling pointer around.

[   66.010905] Unsupported CHAP_A value
[   66.011660] Security negotiation failed.
[   66.012443] iSCSI Login negotiation failed.
[   68.413924] general protection fault: 0000 [#1] SMP PTI
[   68.414962] CPU: 0 PID: 1562 Comm: targetcli Kdump: loaded Not tainted 4.18.0-80.el8.x86_64 #1
[   68.416589] Hardware name: Red Hat KVM, BIOS 0.5.1 01/01/2011
[   68.417677] RIP: 0010:__kmalloc_track_caller+0xc2/0x210

Signed-off-by: Maurizio Lombardi <mlombard@redhat.com>
Reviewed-by: Chris Leech <cleech@redhat.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2019-07-31 07:28:18 +02:00
..
iscsi scsi: iscsi: set auth_protocol back to NULL if CHAP_A value is not supported 2019-07-31 07:28:18 +02:00
loopback
sbp
tcm_fc
Kconfig
Makefile
target_core_alua.c
target_core_alua.h
target_core_configfs.c
target_core_device.c scsi: target: Avoid that EXTENDED COPY commands trigger lock inversion 2018-10-03 17:00:49 -07:00
target_core_fabric_configfs.c
target_core_fabric_lib.c
target_core_file.c
target_core_file.h
target_core_hba.c
target_core_iblock.c
target_core_iblock.h
target_core_internal.h
target_core_pr.c
target_core_pr.h
target_core_pscsi.c
target_core_pscsi.h
target_core_rd.c
target_core_rd.h
target_core_sbc.c
target_core_spc.c scsi: target: use consistent left-aligned ASCII INQUIRY data 2019-01-26 09:37:03 +01:00
target_core_stat.c
target_core_tmr.c
target_core_tpg.c
target_core_transport.c
target_core_ua.c
target_core_ua.h
target_core_user.c
target_core_xcopy.c
target_core_xcopy.h