🇰🇷 한글 설명
Linux kernel의 brcmfmac WiFi 드라이버에서 프로브 실패 시 sdiodev->bus가 NULL이 아닌 에러값으로 설정되어, 이후 정리 과정에서 유효하지 않은 포인터를 통해 리소스 해제를 시도할 때 커널 오류가 발생합니다. 두 함수에서 중복으로 버스를 설정하는 설계 결함으로 인한 메모리 관리 오류입니다.
💡 쉬운 설명
WiFi 드라이버가 시작될 때 문제가 생기면 잘못된 주소값이 저장되어 나중에 정리 단계에서 시스템이 충돌합니다. 펌웨어 누락이나 하드웨어 문제로 초기화 실패 시 발생 가능합니다.
🇺🇸 원문 (English)
In the Linux kernel, the following vulnerability has been resolved:
wifi: brcmfmac: Fix potential kernel oops when probe fails
When probe of the sdio brcmfmac device fails for some reasons (i.e.
missing firmware), the sdiodev->bus is set to error instead of NULL, thus
the cleanup later in brcmf_sdio_remove() tries to free resources via
invalid bus pointer. This happens because sdiodev->bus is set 2 times:
first in brcmf_sdio_probe() and second time in brcmf_sdiod_probe(). Fix
this by chaning the brcmf_sdio_probe() function to return the error code
and set sdio->bus only there.
📍 영향받는 시스템
Linux kernel brcmfmac driver (Broadcom SDIO WiFi 장치)
⚔️ 공격 벡터
로컬 공격. 프로브 실패 조건(펌웨어 누락, 하드웨어 비정상)을 의도적으로 유발하여 커널 oops 발생 가능
🛡️ 대응 방법
Linux kernel을 최신 패치 버전으로 업데이트하여 brcmf_sdio_probe() 함수의 에러 처리 로직 수정
🔧 검증 코드
brcmfmac 모듈이 로드된 경우 영향 받을 수 있으므로, 커널 버전을 확인하여 최신 패치 버전으로 업데이트했는지 확인
grep -i brcmfmac /proc/modules 2>/dev/null && uname -r