🇰🇷 한글 설명
Linux 커널의 bonding 드라이버 내 bond_do_ioctl() 함수에서 NULL 포인터 역참조 취약점이 발견되었습니다. 존재하지 않는 슬레이브 인터페이스 이름을 사용하여 ioctl을 호출할 경우, NULL 체크 이전에 디버그 로그를 출력하려 시도하면서 커널 오류(Kernel Oops)가 발생합니다.
💡 쉬운 설명
네트워크 설정을 변경하는 명령을 내릴 때, 존재하지 않는 장치 이름을 입력하면 컴퓨터의 핵심 시스템인 커널이 갑자기 멈추거나 오류를 일으킬 수 있는 문제입니다. 공격자가 이를 악용하면 시스템을 강제로 중단시킬 수 있습니다.
🇺🇸 원문 (English)
In the Linux kernel, the following vulnerability has been resolved:
net: bonding: fix NULL pointer dereference in bond_do_ioctl()
In bond_do_ioctl(), slave_dev is obtained via __dev_get_by_name() which
can return NULL if the requested interface name does not exist. However,
the subsequent slave_dbg() call is placed before the NULL check:
slave_dev = __dev_get_by_name(net, ifr->ifr_slave);
slave_dbg(bond_dev, slave_dev, "slave_dev=%p:\n", slave_dev); //here
if (!slave_dev)
return -ENODEV;
The slave_dbg() macro expands to netdev_dbg(bond_dev, "(slave %s): " fmt,
(slave_dev)->name, ...) which unconditionally dereferences slave_dev->name
before the NULL check is performed. This results in a NULL pointer
dereference kernel oops when a user calls bonding ioctl (e.g.
SIOCBONDENSLAVE, SIOCBONDRELEASE, etc.) with a non-existent slave
interface name.
This is reachable from userspace via the bonding ioctl interface with
CAP_NET_ADMIN capability, making it a potential local denial-of-service
vector.
Fix by moving the slave_dbg() call after the NULL check.
📍 영향받는 시스템
Linux kernel (bonding driver 사용 시스템)
⚔️ 공격 벡터
CAP_NET_ADMIN 권한을 가진 로컬 사용자가 존재하지 않는 인터페이스 이름을 포함한 bonding ioctl 호출
🛡️ 대응 방법
커널 패치를 적용하여 slave_dbg() 호출 위치를 NULL 체크 이후로 이동
🔧 검증 코드
출력된 커널 버전을 확인하여 해당 취약점이 해결된 최신 패치 버전인지 확인