Request: 2f3835771dff ("scsi: target: iscsi: reject invalid size Extended CDB AHS") for 6.12.y and 6.18.y
Subsystems (3)
Hello,
Please consider 2f3835771dff ("scsi: target: iscsi: reject invalid size Extended CDB AHS") for 6.12.y and 6.18.y. It is in mainline since v7.1-rc3 and reached 7.3.y by inheritance, but it carries no Cc: stable and is absent from 6.12.120 and 6.18.66. It applies cleanly to both branches (git apply --check).
Without it, a zero-length Extended CDB AHS makes iscsit_setup_scsi_cmd() allocate 15 bytes and copy 16, and compute an ahslength - 1 copy length of SIZE_MAX. I reproduced a host panic from one unauthenticated PDU on a target without CHAP (Ubuntu 7.0 kernels; panic_on_oops=1, oops otherwise):
memcpy: detected buffer overflow: 16 byte write of buffer size 15 __fortify_panic <- iscsit_setup_scsi_cmd.cold+0x1a5 [iscsi_target_mod]
Thank you,
James Sawyer
Quoted 2 lines
Please consider
2f3835771dff("scsi: target: iscsi: reject invalid size Extended CDB AHS") for 6.12.y and 6.18.y.
Queued for 6.18, 6.12, 6.6 and 6.1, thanks.
Signature · 2 lines
Thanks, Sasha