🇰🇷 한글 설명
Linux 커널의 lockd 구성 요소에서 nlm_do_fopen() 함수가 실패할 때 nlm_file 객체가 메모리에서 해제되지 않는 메모리 누수 취약점이 발견되었습니다. 공격자가 잘못된 파일 핸들을 반복적으로 제시하여 이 함수를 실패하게 만들면 시스템 메모리가 점진적으로 고갈될 수 있습니다.
💡 쉬운 설명
컴퓨터가 파일을 열려고 시도하다가 실패했을 때, 사용했던 메모리를 다시 돌려주지 않고 계속 쌓아두는 버그입니다. 이 현상이 반복되면 컴퓨터의 메모리가 부족해져 시스템이 느려지거나 멈출 수 있습니다.
🇺🇸 원문 (English)
In the Linux kernel, the following vulnerability has been resolved:
lockd: Plug nlm_file leak when nlm_do_fopen() fails
A client can repeatedly drive nlm_do_fopen() failures by presenting
file handles that the underlying export rejects. After kzalloc_obj()
succeeds in nlm_lookup_file(), the freshly allocated nlm_file is not
yet inserted into nlm_files[]. The nlm_do_fopen() failure path jumps
to out_unlock, which releases nlm_file_mutex and returns without
freeing the allocation, so each failure leaks one nlm_file.
Route the failure through out_free so kfree() runs before the
function returns.
📍 영향받는 시스템
Linux kernel (lockd 구성 요소가 포함된 버전)
⚔️ 공격 벡터
거부된 파일 핸들을 반복적으로 전송하여 nlm_do_fopen() 오류를 유도하는 방식
🛡️ 대응 방법
커널 패치를 적용하여 nlm_do_fopen() 실패 시 kfree()가 호출되도록 수정된 최신 커널로 업데이트
🔧 검증 코드
출력된 커널 버전이 해당 취약점이 수정된 패치 버전 이후인지 확인