🇰🇷 한글 설명
Linux 커널의 nexthop 구조체에서 예약된 필드들이 초기화되지 않아 커널 메모리가 누출되는 취약점입니다. ip nexthop 명령어로 넥스트홉 정보 조회 시 가비지 메모리값이 사용자 공간으로 노출됩니다.
💡 쉬운 설명
Linux 커널이 네트워크 경로 정보를 보낼 때 초기화되지 않은 메모리 영역을 함께 전송합니다. 이를 통해 커널의 민감한 정보가 노출될 수 있습니다.
🇺🇸 원문 (English)
In the Linux kernel, the following vulnerability has been resolved:
net: nexthop: Initialize all fields in dumped nexthops
struct nexthop_grp contains two reserved fields that are not initialized by
nla_put_nh_group(), and carry garbage. This can be observed e.g. with
strace (edited for clarity):
# ip nexthop add id 1 dev lo
# ip nexthop add id 101 group 1
# strace -e recvmsg ip nexthop get id 101
...
recvmsg(... [{nla_len=12, nla_type=NHA_GROUP},
[{id=1, weight=0, resvd1=0x69, resvd2=0x67}]] ...) = 52
The fields are reserved and therefore not currently used. But as they are, they
leak kernel memory, and the fact they are not just zero complicates repurposing
of the fields for new ends. Initialize the full structure.
📍 영향받는 시스템
Linux kernel nexthop 기능을 지원하는 모든 버전 (패치 전)
⚔️ 공격 벡터
ip nexthop 명령어 실행으로 구조체 내 예약 필드(resvd1, resvd2)의 가비지값 수집
🛡️ 대응 방법
Linux 커널을 CVE-2024-42283 패치가 적용된 버전 이상으로 업데이트
🔧 검증 코드
현재 커널 버전이 2024년 하반기 이후 LTS 버전(예: 6.x.x 최신)인지 확인하여 패치 적용 여부 판단