Skip to contentSkip to conversation

aacraid: information leak in aac_send_raw_srb()

PATCH New Dan Carpenter 1 participant 1 message Feb 7, 2017

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 aacraid: information leak in aac_send_raw_srb()

The aac_srb_reply struct ends in a 2 byte hole so we end up leaking a bit of information to user space.

Fixes 423400e64d37 ("scsi: aacraid: Include HBA direct interface")
drivers/scsi/aacraid/commctrl.c +1 -0
index 614842a9eb07..12dc867b7c74 100644
@@ -948,6 +948,7 @@ static int aac_send_raw_srb(struct aac_dev* dev, void __user * arg)
 			&((struct aac_native_hba *)srbfib->hw_fib_va)->resp.err;
 		struct aac_srb_reply reply;
 
+		memset(&reply, 0, sizeof(reply));
 		reply.status = ST_OK;
 		if (srbfib->flags & FIB_CONTEXT_FLAG_FASTRESP) {
 			/* fast response */