linux/drivers/scsi/qla2xxx
Roland Dreier 3578ddba1a tcm_qla2xxx: Don't insert nacls without sessions into the btree
When we create an explicit node ACL in tcm_qla2xxx_make_nodeacl(),
there is a call to tcm_qla2xxx_setup_nacl_from_rport(), which puts the
node ACL into the lport_fcport_map even though there is no session yet
for the initiator.  Since the only time we remove entries from this
map is when we free a session, this means that if we later delete this
node ACL without the initiator ever creating a session, we'll leave
the nacl pointer in the btree pointing at freed memory.

This is especially bad if that initiator later does send us a command
that would cause us to create a dynamic ACL and session: we'll find
the stale freed nacl pointer in the btree and end up with use-after-free.

We could add more code to clear the btree entry when deleting the
explicit nacl, but the original insertion is pointless: without a
session attached, we'll just have to update the entry when a session
appears anyway.  So we can just delete tcm_qla2xxx_setup_nacl_from_rport()
and the code that calls it.

Signed-off-by: Roland Dreier <roland@purestorage.com>
Cc: Chad Dupuis <chad.dupuis@qlogic.com>
Cc: Giridhar Malavali <giridhar.malavali@qlogic.com>
Cc: Arun Easi <arun.easi@qlogic.com>
Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org>
2012-06-12 20:12:25 -07:00
..
Kconfig [SCSI] tcm_qla2xxx: Add >= 24xx series fabric module for target-core 2012-05-22 11:49:20 +01:00
Makefile [SCSI] tcm_qla2xxx: Add >= 24xx series fabric module for target-core 2012-05-22 11:49:20 +01:00
qla_attr.c [SCSI] qla2xxx: Add LLD target-mode infrastructure for >= 24xx series 2012-05-22 11:47:51 +01:00
qla_bsg.c [SCSI] Revert "qla2xxx: During loopdown perform Diagnostic loopback." 2012-05-22 11:47:01 +01:00
qla_bsg.h [SCSI] qla2xxx: Provide method for updating I2C attached VPD. 2011-08-29 00:14:57 -07:00
qla_dbg.c [SCSI] qla2xxx: Add LLD target-mode infrastructure for >= 24xx series 2012-05-22 11:47:51 +01:00
qla_dbg.h [SCSI] qla2xxx: Add LLD target-mode infrastructure for >= 24xx series 2012-05-22 11:47:51 +01:00
qla_def.h [SCSI] qla2xxx: Add LLD target-mode infrastructure for >= 24xx series 2012-05-22 11:47:51 +01:00
qla_devtbl.h [SCSI] qla2xxx: fix Kernel Panic with Qlogic 2472 Card. 2009-02-10 11:15:18 -05:00
qla_dfs.c [SCSI] qla2xxx: Enhancements to support ISP83xx. 2012-02-19 08:11:11 -06:00
qla_fw.h [SCSI] qla2xxx: Enhancements to support ISP83xx. 2012-02-19 08:11:11 -06:00
qla_gbl.h [SCSI] qla2xxx: Add LLD target-mode infrastructure for >= 24xx series 2012-05-22 11:47:51 +01:00
qla_gs.c [SCSI] qla2xxx: Add LLD target-mode infrastructure for >= 24xx series 2012-05-22 11:47:51 +01:00
qla_init.c [SCSI] qla2xxx: Add LLD target-mode infrastructure for >= 24xx series 2012-05-22 11:47:51 +01:00
qla_inline.h [SCSI] qla2xxx: Add ha->max_fibre_devices to keep track of the maximum number of targets. 2012-02-19 08:33:13 -06:00
qla_iocb.c [SCSI] qla2xxx: don't free pool that wasn't allocated 2012-05-22 11:52:20 +01:00
qla_isr.c [SCSI] qla2xxx: Add LLD target-mode infrastructure for >= 24xx series 2012-05-22 11:47:51 +01:00
qla_mbx.c [SCSI] qla2xxx: Add LLD target-mode infrastructure for >= 24xx series 2012-05-22 11:47:51 +01:00
qla_mid.c [SCSI] qla2xxx: Add LLD target-mode infrastructure for >= 24xx series 2012-05-22 11:47:51 +01:00
qla_nx.c [SCSI] qla2xxx: Display proper firmware version when new minidump template is gathered for ISP82xx. 2012-05-22 11:45:15 +01:00
qla_nx.h [SCSI] qla2xxx: Corrections to log messages. 2012-05-22 11:39:52 +01:00
qla_os.c SCSI misc on 20120531 2012-05-31 12:02:41 -07:00
qla_settings.h [SCSI] qla2xxx: Update copyright banner. 2011-05-01 10:07:23 -05:00
qla_sup.c [SCSI] qla2xxx: Block flash access from application when device is initialized for ISP82xx. 2012-05-10 08:10:58 +01:00
qla_target.c [SCSI] qla2xxx: Add LLD target-mode infrastructure for >= 24xx series 2012-05-22 11:47:51 +01:00
qla_target.h [SCSI] qla2xxx: Add LLD target-mode infrastructure for >= 24xx series 2012-05-22 11:47:51 +01:00
qla_version.h [SCSI] qla2xxx: Update version number to 8.04.00.03-k. 2012-05-10 08:19:10 +01:00
tcm_qla2xxx.c tcm_qla2xxx: Don't insert nacls without sessions into the btree 2012-06-12 20:12:25 -07:00
tcm_qla2xxx.h [SCSI] tcm_qla2xxx: Add >= 24xx series fabric module for target-core 2012-05-22 11:49:20 +01:00