🔍 CVE-2025-39805

5.5
CVSS Score
MEDIUM
2025-09-16
2026-10-19 21:10
✅ 완료

🇰🇷 한글 설명

Linux 커널의 macb 드라이버에서 장치 제거 시 unregister_netdev() 호출 순서가 잘못되어 발생하는 취약점입니다. PHY를 먼저 종료한 후 네트워크 장치를 해제하면서 kernfs에서 경고(WARNING)가 발생하며 시스템 안정성에 영향을 줄 수 있습니다.

💡 쉬운 설명

컴퓨터 부품을 제거할 때 순서가 잘못되어 시스템이 당황하며 경고 메시지를 내보내는 문제입니다. 네트워크 장치를 먼저 안전하게 등록 해제한 뒤 부품 연결을 끊어야 하는데, 그 반대로 동작하여 발생합니다.

🇺🇸 원문 (English)

In the Linux kernel, the following vulnerability has been resolved: net: macb: fix unregister_netdev call order in macb_remove() When removing a macb device, the driver calls phy_exit() before unregister_netdev(). This leads to a WARN from kernfs: ------------[ cut here ]------------ kernfs: can not remove 'attached_dev', no directory WARNING: CPU: 1 PID: 27146 at fs/kernfs/dir.c:1683 Call trace: kernfs_remove_by_name_ns+0xd8/0xf0 sysfs_remove_link+0x24/0x58 phy_detach+0x5c/0x168 phy_disconnect+0x4c/0x70 phylink_disconnect_phy+0x6c/0xc0 [phylink] macb_close+0x6c/0x170 [macb] ... macb_remove+0x60/0x168 [macb] platform_remove+0x5c/0x80 ... The warning happens because the PHY is being exited while the netdev is still registered. The correct order is to unregister the netdev before shutting down the PHY and cleaning up the MDIO bus. Fix this by moving unregister_netdev() ahead of phy_exit() in macb_remove().

📍 영향받는 시스템

macb 드라이버를 사용하는 Linux 커널 시스템

⚔️ 공격 벡터

로컬 시스템에서 장치 제거(remove) 동작을 유도하여 커널 경고 발생 가능

🛡️ 대응 방법

macb_remove() 함수 내에서 unregister_netdev()를 phy_exit()보다 먼저 호출하도록 커널 패치 적용

🔧 검증 코드

현재 실행 중인 커널 버전을 확인하여 해당 취약점이 수정된 최신 패치 버전인지 확인합니다.

Shell / Script
uname -r

📊 CVSS Vector String

CVSS Vector
CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H

💻 영향받는 소프트웨어

Linux Kernel