Browse Source

[iscsi] Verify the correct tag in NOP-In PDUs

We should be checking the target transfer tag, rather than the
initiator task tag.

Signed-off-by: Michael Brown <mcb30@ipxe.org>
tags/v1.20.1
Michael Brown 14 years ago
parent
commit
9625132bf5
1 changed files with 4 additions and 4 deletions
  1. 4
    4
      src/net/tcp/iscsi.c

+ 4
- 4
src/net/tcp/iscsi.c View File

617
 	 * (not the reserved 0xffffffff), the initiator MUST respond
617
 	 * (not the reserved 0xffffffff), the initiator MUST respond
618
 	 * with a NOP-Out".  Since we never send unsolicited NOP-Outs,
618
 	 * with a NOP-Out".  Since we never send unsolicited NOP-Outs,
619
 	 * my reading of this is that we can handle all permitted
619
 	 * my reading of this is that we can handle all permitted
620
-	 * NOP-Ins (which must have ITT set to 0xffffffff) by simply
620
+	 * NOP-Ins (which must have TTT set to 0xffffffff) by simply
621
 	 * ignoring them.
621
 	 * ignoring them.
622
 	 *
622
 	 *
623
 	 * There is some ambiguity in the RFC, since there are other
623
 	 * There is some ambiguity in the RFC, since there are other
628
 	 * rather than just having the target drop the connection when
628
 	 * rather than just having the target drop the connection when
629
 	 * it times out waiting for the NOP-Out response.
629
 	 * it times out waiting for the NOP-Out response.
630
 	 */
630
 	 */
631
-	if ( nop_in->itt != htonl ( ISCSI_TAG_RESERVED ) ) {
632
-		DBGC ( iscsi, "iSCSI %p received invalid NOP-In with ITT "
633
-		       "%08x\n", iscsi, ntohl ( nop_in->itt ) );
631
+	if ( nop_in->ttt != htonl ( ISCSI_TAG_RESERVED ) ) {
632
+		DBGC ( iscsi, "iSCSI %p received invalid NOP-In with TTT "
633
+		       "%08x\n", iscsi, ntohl ( nop_in->ttt ) );
634
 		return -EPROTO_INVALID_NOP_IN;
634
 		return -EPROTO_INVALID_NOP_IN;
635
 	}
635
 	}
636
 
636
 

Loading…
Cancel
Save