🇰🇷 한글 설명
Linux 커널의 qla2xxx SCSI 드라이버에서 bsg 스택 버퍼가 초기화되지 않아 발생하는 정보 유출 취약점입니다. 특정 핸들러가 요청 데이터보다 큰 버퍼를 복사할 때 스택에 남아있던 이전 데이터가 사용자 공간으로 노출될 수 있습니다.
💡 쉬운 설명
컴퓨터 메모리의 일부 공간이 깨끗하게 비워지지 않은 상태로 사용되어, 이전에 저장되었던 중요한 정보가 외부로 흘러나갈 수 있는 문제입니다. 이를 방지하기 위해 메모리를 사용하기 전 항상 0으로 초기화하는 과정이 필요합니다.
🇺🇸 원문 (English)
In the Linux kernel, the following vulnerability has been resolved:
scsi: qla2xxx: Zero-init bsg stack buffers to avoid info leak
Several bsg handlers stage their request/reply in an uninitialized 256-byte
on-stack buffer (uint8_t bsg[DMA_POOL_SIZE]) and fill it via
sg_copy_to_buffer(), which only copies as many bytes as the user-supplied
request payload. When the request is shorter than the structure, the
remainder of the buffer is left holding stale stack data.
qla2x00_read_fru_status() and qla2x00_read_i2c() then copy the full
structure back to the reply payload with sg_copy_from_buffer(), leaking the
uninitialized stack bytes to user space. The write/update paths do not copy
the buffer back, but can feed uninitialized fields to the device.
Zero the stack buffer at declaration in all five handlers, mirroring the
heap kzalloc() approach, so short requests can no longer expose stale
memory.
📍 영향받는 시스템
Linux kernel (qla2xxx SCSI driver 포함 버전)
⚔️ 공격 벡터
조작된 크기의 SCSI 요청을 보내 스택에 남아있는 잔류 데이터를 읽어내는 방식
🛡️ 대응 방법
Linux 커널을 최신 보안 패치가 적용된 버전으로 업데이트
🔧 검증 코드
출력된 커널 버전이 해당 취약점이 해결된 패치 버전 이후인지 확인