🇰🇷 한글 설명
Linux 커널의 nfc: st21nfca 드라이버에서 수신된 프레임 크기를 적절히 검증하지 않아 발생하는 취약점입니다. 악의적으로 조작된 프레임이 전달될 경우 바이트 언스테핑(unstuffing) 과정에서 메모리 경계를 벗어나 읽기 오류가 발생할 수 있습니다.
💡 쉬운 설명
NFC 통신 과정에서 데이터의 길이를 제대로 확인하지 않아 발생하는 문제입니다. 잘못된 데이터가 들어오면 컴퓨터의 메모리 영역을 넘어서 읽게 되어 시스템 오류를 일으킬 수 있습니다.
🇺🇸 원문 (English)
In the Linux kernel, the following vulnerability has been resolved:
nfc: st21nfca: validate received frame size
st21nfca_hci_i2c_repack() trims a received frame at its EOF marker
before removing byte stuffing. It then assumes the truncated frame
contains the LLC header and two CRC bytes, and it unconditionally reads
the byte after an escape marker.
A malformed frame can place EOF immediately after the start marker or can
end its data portion with an escape marker. The former leaves too few
bytes for check_crc(), while the latter makes the unstuffing loop read past
the current skb length.
Require the minimum framing bytes both before and after unstuffing. Use
separate input and output cursors while removing byte stuffing, and reject
an escape marker without its encoded byte. This keeps malformed frames
within the received frame boundary before CRC processing.
📍 영향받는 시스템
Linux kernel (nfc: st21nfca driver 포함 버전)
⚔️ 공격 벡터
조작된 NFC 프레임을 전송하여 드라이버의 메모리 경계 외 읽기 유도
🛡️ 대응 방법
Linux 커널을 최신 보안 패치가 적용된 버전으로 업데이트
🔧 검증 코드
출력된 커널 버전이 해당 취약점이 해결된 패치 버전 이후인지 확인