🇰🇷 한글 설명
Linux 커널의 mwifiex 드라이버에서 인증 프레임 길이를 계산할 때 size_t 타입을 u16 타입으로 저장하면서 발생하는 정수 오버플로 취약점입니다. 이로 인해 실제 데이터 크기보다 작은 메모리 영역이 할당되어 힙 버퍼 오버플로가 발생할 수 있습니다.
💡 쉬운 설명
무선 랜 드라이버가 데이터의 길이를 잘못 계산하여, 준비된 공간보다 훨씬 큰 데이터를 메모리에 강제로 집어넣는 문제입니다. 이로 인해 시스템이 충돌하거나 해커가 시스템 권한을 탈취할 위험이 있습니다.
🇺🇸 원문 (English)
In the Linux kernel, the following vulnerability has been resolved:
wifi: mwifiex: prevent authentication frame length truncation
mwifiex_cfg80211_authenticate() derives the authentication frame length
from req->ie_len and req->auth_data_len, both of type size_t, but stores
it in a u16.
NL80211_ATTR_AUTH_DATA only has a minimum length policy. Since nla_len is
a u16, a single attribute can carry up to 65531 bytes of payload, so the
sum can exceed U16_MAX before it is assigned to pkt_len. The truncated
pkt_len determines the skb frame area, while the copy length remains
req->auth_data_len - 4, resulting in a heap buffer overflow.
For example, with auth_data_len equal to 65510 and no IEs, the sum is
65546. It is truncated to 10 and then reduced by four to 6. The driver
appends only six bytes to the skb with skb_put(), but then copies 65506
user-provided bytes into the authentication body.
Reaching this path requires CAP_NET_ADMIN in the user namespace owning
the network namespace, an up station netdev, and a suitable BSS/SAE
authentication request.
Compute the length in size_t, reject values that cannot be represented by
the firmware's u16 frame length field, and only then assign it to pkt_len.
📍 영향받는 시스템
Linux kernel (mwifiex driver 포함 버전)
⚔️ 공격 벡터
CAP_NET_ADMIN 권한을 가진 사용자가 조작된 인증 프레임 길이를 가진 네트워크 요청을 전송
🛡️ 대응 방법
커널을 최신 보안 패치가 적용된 버전으로 업데이트하여 길이를 검증하는 로직을 적용해야 함
🔧 검증 코드
출력된 커널 버전이 해당 취약점이 수정된 패치 버전 이후인지 확인
💻 영향받는 소프트웨어
NVIDIA Cloud Gaming Guest Driver for Linux