🇰🇷 한글 설명
Linux 커널의 SCSI iSCSI 타겟 구현에서 로그인 페이로드 처리 시 NUL 종료 문자가 누락되는 취약점이 발견되었습니다. 공격자가 특정 길이의 로그인 PDU를 전송할 경우, 버퍼 오버런이 발생하여 인접한 슬랩 메모리 영역을 침범할 수 있습니다. 이는 인증되지 않은 이니시에이터가 CHAP 인증이 설정된 포털을 대상으로 공격할 수 있음을 의미합니다.
💡 쉬운 설명
컴퓨터가 데이터를 읽을 때 데이터의 끝을 알려주는 표시가 없어서, 데이터가 끝난 뒤에도 메모리의 다른 부분을 계속 읽어버리는 문제입니다. 이를 통해 해커가 시스템의 중요한 정보를 훔쳐보거나 메모리를 조작할 위험이 있습니다.
🇺🇸 원문 (English)
In the Linux kernel, the following vulnerability has been resolved:
scsi: target: iscsi: Reserve a terminator byte for the login payload
iscsi_target_check_login_request() rejects a login PDU whose
DataSegmentLength exceeds MAX_KEY_VALUE_PAIRS, but the test is '>' and
login->req_buf is allocated with exactly MAX_KEY_VALUE_PAIRS
bytes. Since iscsit_get_login_rx() receives payload_length + padding
bytes, where
padding = ((-payload_length) & 3);
any payload_length from 8189 to 8192 fills the whole 8192 byte
buffer. The write stays in bounds, but no byte is left for a NUL
terminator.
The buffer is subsequently consumed as a C string. In the CHAP path
chap_check_algorithm() calls kstrdup(a_str), and extract_param() calls
strstr(in_buf, pattern) followed by strlen_semi(), none of which take a
length. convert_null_to_semi() additionally rewrites every embedded NUL
to ';', so even a payload made of well formed NUL separated key=value
records is left without a terminator. These walk past the end of the
object into adjacent slab memory. It is reachable by an unauthenticated
initiator against a portal configured for CHAP; when authentication is
not required iscsi_login_zero_tsih_s2() rewrites AuthMethod to None and
the CHAP path is never entered.
Allocate one extra byte. kzalloc() zeroes it and nothing ever writes to
it, as every writer copies to offset 0 for at most MAX_KEY_VALUE_PAIRS
bytes, so the buffer is always terminated.
📍 영향받는 시스템
Linux kernel (iSCSI target component)
⚔️ 공격 벡터
인증되지 않은 이니시에이터가 CHAP 인증이 활성화된 iSCSI 포털로 특정 길이의 로그인 PDU 전송
🛡️ 대응 방법
커널 패치를 적용하여 로그인 페이로드 버퍼 할당 시 NUL 종료 문자를 위한 1바이트를 추가로 할당하도록 업데이트
🔧 검증 코드
현재 실행 중인 커널 버전을 확인하여 해당 취약점이 해결된 패치 버전인지 보안 공지(CVE-2026-90011)와 대조하여 확인