🇰🇷 한글 설명
리눅스 커널의 mac80211 mesh_rx_csa_frame() 함수에서 메시 채널 스위치 파라미터 IE가 없는 경우 NULL 포인터 역참조 취약점이 발생합니다. 원격 메시 피어가 Mesh ID와 Mesh Configuration IE는 포함하지만 Mesh Channel Switch Parameters IE를 생략한 CSA 액션 프레임을 전송하여 커널 패닉을 유발할 수 있습니다.
💡 쉬운 설명
와이파이 메시 네트워크에서 특별하게 만든 채널 전환 신호를 보내면 리눅스 커널이 메모리에 접근하지 못해 시스템이 충돌합니다. 기본 메시 네트워크 설정으로 충분하며 추가 인증이 필요 없습니다.
🇺🇸 원문 (English)
In the Linux kernel, the following vulnerability has been resolved:
wifi: mac80211: fix NULL pointer dereference in mesh_rx_csa_frame()
In mesh_rx_csa_frame(), elems->mesh_chansw_params_ie is dereferenced
at lines 1638 and 1642 without a prior NULL check:
ifmsh->chsw_ttl = elems->mesh_chansw_params_ie->mesh_ttl;
...
pre_value = le16_to_cpu(elems->mesh_chansw_params_ie->mesh_pre_value);
The mesh_matches_local() check above only validates the Mesh ID,
Mesh Configuration, and Supported Rates IEs. It does not verify the
presence of the Mesh Channel Switch Parameters IE (element ID 118).
When a received CSA action frame omits that IE, ieee802_11_parse_elems()
leaves elems->mesh_chansw_params_ie as NULL, and the unconditional
dereference causes a kernel NULL pointer dereference.
A remote mesh peer with an established peer link (PLINK_ESTAB) can
trigger this by sending a crafted SPECTRUM_MGMT/CHL_SWITCH action frame
that includes a matching Mesh ID and Mesh Configuration IE but omits the
Mesh Channel Switch Parameters IE. No authentication beyond the default
open mesh peering is required.
Crash confirmed on kernel 6.17.0-5-generic via mac80211_hwsim:
BUG: kernel NULL pointer dereference, address: 0000000000000000
Oops: Oops: 0000 [#1] SMP NOPTI
RIP: 0010:ieee80211_mesh_rx_queued_mgmt+0x143/0x2a0 [mac80211]
CR2: 0000000000000000
Fix by adding a NULL check for mesh_chansw_params_ie after
mesh_matches_local() returns, consistent with how other optional IEs
are guarded throughout the mesh code.
The bug has been present since v3.13 (released 2014-01-19).
📍 영향받는 시스템
Linux kernel v3.13 이상 (2014-01-19 이후), mac80211 모듈 포함 메시 네트워킹 활성화 시스템
⚔️ 공격 벡터
SPECTRUM_MGMT/CHL_SWITCH 액션 프레임을 Mesh Channel Switch Parameters IE 없이 전송하여 메시 피어로부터 원격 트리거 가능
🛡️ 대응 방법
Linux 커널을 NULL 체크 패치가 포함된 최신 버전으로 업데이트
🔧 검증 코드
커널 버전과 mac80211 모듈 버전을 확인하여 보안 패치 적용 여부를 판단합니다. 최신 커널로 업데이트되었다면 취약점이 해결되었을 가능성이 높습니다.
uname -r | grep -E '^[0-9]+\.[0-9]+\.[0-9]+' && modinfo mac80211 2>/dev/null | grep -i version