🇰🇷 한글 설명
Linux 커널의 mxl862xx 드라이버에서 DSA(Distributed Switch Architecture) 설정 중 오류가 발생할 경우, 이미 해제된 포트 리스트를 참조하여 발생하는 Use-After-Free 취약점입니다. 통계 수집(stats poll) 작업이 적절히 중단되지 않아 시스템 종료 또는 등록 실패 시 메모리 오류를 유발할 수 있습니다.
💡 쉬운 설명
네트워크 장치를 설정하는 과정에서 오류가 생겼을 때, 이미 사라진 장치 정보를 계속 읽으려고 시도하여 시스템이 충돌하거나 오류가 발생하는 문제입니다. 장치가 꺼질 때 작업이 완전히 멈추지 않아 발생하는 현상입니다.
🇺🇸 원문 (English)
In the Linux kernel, the following vulnerability has been resolved:
net: dsa: mxl862xx: disable the stats poll on teardown
mxl862xx_setup() arms the stats poll before mxl862xx_setup_mdio(), and
nothing stops it until dsa_register_switch() has returned an error to
mxl862xx_probe(). DSA frees the dsa_port list before it returns, so a
poll that fires once .setup or a later step of dsa_tree_setup() has
failed walks freed ports. On shutdown the user ports stay registered,
and the WORK_STOPPED flag test in mxl862xx_get_stats64() is not atomic
with the cancel in mxl862xx_shutdown(), so a re-arm that read the flag
before it was set queues the poll after cancel_delayed_work_sync() has
returned.
Arm the poll once .setup has succeeded and stop it from a .teardown op,
which DSA calls on unregister and after a failed registration, in both
cases before it frees the ports. Use disable_delayed_work_sync() there
and in shutdown(): it drains a running poll as the cancel did and turns
every later attempt to queue the work into a no-op, so the re-arm
cannot bring the poll back. remove() and the probe error path only set
WORK_STOPPED, which crc_err_work tests before it walks the ports.
📍 영향받는 시스템
Linux kernel (mxl862xx driver components)
⚔️ 공격 벡터
로컬 시스템에서 네트워크 드라이버 설정 오류를 유도하거나 장치 해제 시점을 이용한 메모리 참조 오류 유발
🛡️ 대응 방법
Linux 커널을 최신 보안 패치가 적용된 버전으로 업데이트하여 mxl862xx 드라이버의 통계 수집 로직을 수정해야 합니다.
🔧 검증 코드
출력된 커널 버전이 해당 취약점이 해결된 패치 버전 이후인지 확인합니다.