🇰🇷 한글 설명
Linux 커널의 nfsd 구성 요소에서 레이아웃 펜스 워커의 이중 참조 경합 조건(race condition) 취약점이 발견되었습니다. 이로 인해 레이아웃 상태 ID(stateid)가 적절히 해제되지 않고 메모리에 누수되는 문제가 발생합니다.
💡 쉬운 설명
컴퓨터가 작업을 처리하는 과정에서 순서가 꼬여서, 사용이 끝난 데이터 정보를 메모리에서 지우지 못하고 계속 쌓아두는 버그입니다. 이 문제가 반복되면 시스템의 메모리가 점차 부족해질 수 있습니다.
🇺🇸 원문 (English)
In the Linux kernel, the following vulnerability has been resolved:
nfsd: fix layout fence worker double-reference race
The workqueue core clears WORK_STRUCT_PENDING before the callback
is invoked, so delayed_work_pending() in lm_breaker_timedout() can
return false while the fence worker is already running. This lets
the breaker take a duplicate sc_count reference and schedule a new
worker that coalesces with the in-progress one. The extra reference
is never put, leaking the layout stateid.
Replace the racy delayed_work_pending() check with an
ls_fence_inflight boolean set atomically with
refcount_inc_not_zero() under ls_lock, and cleared under ls_lock
before the final nfs4_put_stid() on the dispose path; the retry
path intentionally retains it. Remove the self-rearm
mod_delayed_work() at the top of the worker.
📍 영향받는 시스템
Linux Kernel (nfsd 모듈 사용 시스템)
⚔️ 공격 벡터
특정 NFS4 레이아웃 요청을 반복적으로 발생시켜 경합 조건을 유도함으로써 메모리 누수를 유발
🛡️ 대응 방법
Linux 커널을 최신 보안 패치가 적용된 버전으로 업데이트
🔧 검증 코드
출력된 커널 버전이 해당 취약점이 해결된 패치 버전 이후인지 확인