🇰🇷 한글 설명
Linux 커널의 qla2xxx SCSI 드라이버에서 LS 거부 오류 발생 시 NVMe 미해결 컨텍스트(uctx)를 메모리에서 해제하기 전에 리스트에서 제거하지 않는 취약점이 발견되었습니다. 이로 인해 해제된 메모리 노드가 리스트에 남아 있어, 이후 리스트 조작 시 메모리 오염이나 시스템 커널 패닉을 유발할 수 있습니다.
💡 쉬운 설명
컴퓨터가 사용이 끝난 메모리 정보를 목록에서 지우지 않고 그냥 버리는 오류가 있습니다. 이 때문에 나중에 컴퓨터가 목록을 정리하려 할 때 엉뚱한 곳을 건드려 시스템이 멈추거나 고장 날 수 있습니다.
🇺🇸 원문 (English)
In the Linux kernel, the following vulnerability has been resolved:
scsi: qla2xxx: Unlink NVMe unsol ctx before freeing on LS reject error
qla_nvme_xmt_ls_rsp() obtains uctx, which was linked into
fcport->unsol_ctx_head by qla2xxx_process_purls_iocb() and is still linked
when the NVMe transport calls back to transmit the LS response. On the
error (out:) path the function frees uctx with kfree() but never removes
it from the list. This leaves a freed node in fcport->unsol_ctx_head: the
next list_add_tail() for that fcport writes through the freed node, and a
subsequent list_del() can corrupt the list or panic.
Unlink uctx with list_del() before kfree() on the error path, matching the
other free sites in qla_nvme_release_lsrsp_cmd_kref() and
qla2xxx_process_purls_pkt(). qla2x00_rel_sp() in the failure path only
returns the SRB to its pool and does not invoke sp->put_fn, so the out:
path is the sole free and uctx is always still linked there.
📍 영향받는 시스템
Linux kernel (qla2xxx SCSI driver 사용 시스템)
⚔️ 공격 벡터
특수하게 조작된 LS(Link Service) 응답을 통해 드라이버의 오류 경로를 유도하여 메모리 오염 유발
🛡️ 대응 방법
qla2xxx 드라이버의 오류 처리 로직에 list_del()를 추가하여 메모리 해제 전 리스트에서 노드를 제거하도록 커널 업데이트
🔧 검증 코드
현재 실행 중인 커널 버전을 확인하여 해당 취약점이 패치된 최신 보안 업데이트 버전인지 확인합니다.