🇰🇷 한글 설명
Linux 커널의 NFC LLCP 구성 요소에서 발생한 취약점으로, 잘못된 optlen 값을 사용할 경우 사용자 공간 버퍼에 오버플로우가 발생할 수 있습니다. nfc_llcp_getsockopt() 함수가 사용자로부터 전달받은 길이와 상관없이 항상 4바이트를 저장하여 메모리 경계를 침범하는 문제가 있었습니다.
💡 쉬운 설명
컴퓨터가 데이터를 저장할 때, 사용자가 요청한 공간보다 더 많은 데이터를 억지로 밀어 넣어 메모리 오류를 일으키는 문제입니다. 이로 인해 시스템이 불안정해지거나 보안 문제가 생길 수 있습니다.
🇺🇸 원문 (English)
In the Linux kernel, the following vulnerability has been resolved:
nfc: llcp: avoid userspace overflow on invalid optlen
nfc_llcp_getsockopt() casts optval to (u32 __user *) for put_user(), so
the kernel always stores 4 bytes regardless of the caller-supplied
optlen. The existing min_t(u32, len, sizeof(u32)) only clamps the length
reported back to userspace; it does not constrain the store. A call with
optlen < 4 therefore writes past the user buffer, violating the
getsockopt(2) contract for all five supported optnames.
Reject any call with optlen < sizeof(u32) up front. 'len' is int, so a
plain size comparison would promote a negative optlen to size_t and slip
past the check; an explicit 'len < 0' test is added first to catch
negative values before the size compare.
📍 영향받는 시스템
Linux kernel (NFC LLCP module 포함 버전)
⚔️ 공격 벡터
사용자 공간에서 잘못된 크기의 optlen 값을 가진 getsockopt(2) 시스템 호출을 수행하여 발생
🛡️ 대응 방법
NFC LLCP 관련 커널 패치를 적용하여 optlen이 4바이트 미만이거나 음수인 경우를 차단해야 함
🔧 검증 코드
출력된 커널 버전이 취약점이 해결된 최신 보안 패치 버전인지 확인하십시오.