🔍 CVE-2025-37864

5.5
CVSS Score
MEDIUM
2025-05-09
2026-06-01 17:16
✅ 완료

🇰🇷 한글 설명

Linux 커널의 DSA(Distributed Switch Architecture) 드라이버에서 장치 언바인드(unbind) 시 FDB, MDB, VLAN 엔트리가 제대로 정리되지 않는 취약점입니다. 특정 상황에서 브리지 바이패스 작업이나 VLAN 삭제 실패로 인해 네트워크 엔트리가 메모리에 남아 리소스 누수가 발생할 수 있습니다.

💡 쉬운 설명

네트워크 스위치 기능을 담당하는 소프트웨어가 종료될 때, 사용하던 설정 정보들을 깨끗이 지우지 못하고 남겨두는 문제입니다. 이로 인해 시스템의 메모리가 조금씩 낭비될 수 있습니다.

🇺🇸 원문 (English)

In the Linux kernel, the following vulnerability has been resolved: net: dsa: clean up FDB, MDB, VLAN entries on unbind As explained in many places such as commit b117e1e8a86d ("net: dsa: delete dsa_legacy_fdb_add and dsa_legacy_fdb_del"), DSA is written given the assumption that higher layers have balanced additions/deletions. As such, it only makes sense to be extremely vocal when those assumptions are violated and the driver unbinds with entries still present. But Ido Schimmel points out a very simple situation where that is wrong: https://lore.kernel.org/netdev/ZDazSM5UsPPjQuKr@shredder/ (also briefly discussed by me in the aforementioned commit). Basically, while the bridge bypass operations are not something that DSA explicitly documents, and for the majority of DSA drivers this API simply causes them to go to promiscuous mode, that isn't the case for all drivers. Some have the necessary requirements for bridge bypass operations to do something useful - see dsa_switch_supports_uc_filtering(). Although in tools/testing/selftests/net/forwarding/local_termination.sh, we made an effort to popularize better mechanisms to manage address filters on DSA interfaces from user space - namely macvlan for unicast, and setsockopt(IP_ADD_MEMBERSHIP) - through mtools - for multicast, the fact is that 'bridge fdb add ... self static local' also exists as kernel UAPI, and might be useful to someone, even if only for a quick hack. It seems counter-productive to block that path by implementing shim .ndo_fdb_add and .ndo_fdb_del operations which just return -EOPNOTSUPP in order to prevent the ndo_dflt_fdb_add() and ndo_dflt_fdb_del() from running, although we could do that. Accepting that cleanup is necessary seems to be the only option. Especially since we appear to be coming back at this from a different angle as well. Russell King is noticing that the WARN_ON() triggers even for VLANs: https://lore.kernel.org/netdev/[email protected]/ What happens in the bug report above is that dsa_port_do_vlan_del() fails, then the VLAN entry lingers on, and then we warn on unbind and leak it. This is not a straight revert of the blamed commit, but we now add an informational print to the kernel log (to still have a way to see that bugs exist), and some extra comments gathered from past years' experience, to justify the logic.

📍 영향받는 시스템

Linux kernel (DSA driver 사용 환경)

⚔️ 공격 벡터

로컬 시스템에서 네트워크 인터페이스를 빈번하게 언바인드하거나 특정 네트워크 설정을 조작하여 리소스 누수를 유도

🛡️ 대응 방법

Linux 커널을 최신 보안 패치가 적용된 버전으로 업데이트

🔧 검증 코드

출력된 커널 버전이 해당 취약점이 수정된 패치 버전 이후인지 확인

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