🇰🇷 한글 설명
Linux 커널의 mv88e6xxx 드라이버에서 정책 규칙을 덤프할 때 호출자의 버퍼 크기를 제대로 제한하지 않는 취약점이 발견되었습니다. 이로 인해 관리자가 설정한 규칙을 일반 사용자가 요청할 때 버퍼 범위를 벗어나 메모리를 오염시키거나 NULL 포인터를 역참조할 수 있습니다.
💡 쉬운 설명
네트워크 장비 설정 정보를 가져올 때, 사용자가 준비한 공간보다 더 많은 정보를 강제로 쓰려고 시도하여 시스템 오류를 일으킬 수 있는 문제입니다. 이를 통해 시스템이 멈추거나 보안 설정이 무력화될 위험이 있습니다.
🇺🇸 원문 (English)
In the Linux kernel, the following vulnerability has been resolved:
net: dsa: mv88e6xxx: bound the policy rule dump by the caller's buffer size
mv88e6xxx_get_rxnfc() uses rxnfc->rule_cnt as the write index while
dumping the policy IDR, clobbering the input value before it has been
looked at. That input is the number of entries the caller had room for.
ETHTOOL_GRXCLSRLALL requires no CAP_NET_ADMIN and the ioctl sizes the
buffer from the rule_cnt userspace passes in, so once an admin has
installed policy rules any user can ask for fewer slots than there are
rules and run off the end of the allocation. A rule_cnt of 0 leaves the
buffer pointer NULL and the walk dereferences it.
Count into a local so the caller's limit survives the walk, and stop with
-EMSGSIZE once it is reached.
📍 영향받는 시스템
Linux kernel (mv88e6xxx driver)
⚔️ 공격 벡터
권한이 없는 로컬 사용자가 ETHTOOL_GRXCLSRLALL ioctl 호출을 통해 조작된 rule_cnt 값을 전달하여 메모리 오버플로우 유도
🛡️ 대응 방법
Linux 커널을 최신 보안 패치가 적용된 버전으로 업데이트하십시오.
🔧 검증 코드
출력된 커널 버전이 해당 취약점이 수정된 패치 버전 이후인지 확인하십시오.