🇰🇷 한글 설명
Linux 커널의 SCSI iSCSI 타겟 구성 요소에서 login_work와 로그인 스레드 간의 레이스 컨디션 취약점이 발견되었습니다. 악의적인 이니시에이터가 로그인 PDU 직후 임의의 데이터를 전송할 경우, 로그인 완료 후에도 플래그가 해제되지 않아 커널이 해제된 소켓 구조체를 참조하게 되어 시스템이 충돌(Crash)할 수 있습니다.
💡 쉬운 설명
로그인 과정 중에 특수한 데이터를 보내 시스템을 혼란에 빠뜨려 컴퓨터를 강제로 멈추게 만드는 오류입니다. 공격자가 이 방법을 사용하면 서버의 운영체제가 갑자기 꺼지거나 재부팅될 수 있습니다.
🇺🇸 원문 (English)
In the Linux kernel, the following vulnerability has been resolved:
scsi: target: iscsi: Fix a race condition between login_work and the login thread
In case a malicious initiator sends some random data immediately after a
login PDU; the iscsi_target_sk_data_ready() callback will schedule the
login_work and, at the same time, the negotiation may end without clearing
the LOGIN_FLAGS_INITIAL_PDU flag (because no additional PDU exchanges are
required to complete the login).
The login has been completed but the login_work function will find the
LOGIN_FLAGS_INITIAL_PDU flag set and will never stop from rescheduling
itself; at this point, if the initiator drops the connection, the
iscsit_conn structure will be freed, login_work will dereference a released
socket structure and the kernel crashes.
BUG: kernel NULL pointer dereference, address: 0000000000000230
PF: supervisor write access in kernel mode
PF: error_code(0x0002) - not-present page
Workqueue: events iscsi_target_do_login_rx [iscsi_target_mod]
RIP: 0010:_raw_read_lock_bh+0x15/0x30
Call trace:
iscsi_target_do_login_rx+0x75/0x3f0 [iscsi_target_mod]
process_one_work+0x1e8/0x3c0
Fix this bug by forcing login_work to stop after the login has been
completed and the socket callbacks have been restored.
Add a comment to clearify the return values of iscsi_target_do_login()
📍 영향받는 시스템
Linux Kernel (iSCSI target module 포함 버전)
⚔️ 공격 벡터
악의적인 iSCSI 이니시에이터가 로그인 PDU 직후 임의의 데이터를 전송하여 레이스 컨디션 유발
🛡️ 대응 방법
Linux 커널을 최신 보안 패치가 적용된 버전으로 업데이트하여 login_work가 로그인 완료 후 정상적으로 중단되도록 수정
🔧 검증 코드
출력된 커널 버전이 해당 취약점이 해결된 패치 버전 이후인지 확인