🇰🇷 한글 설명
Linux 커널의 nfsd 구성 요소에서 splice read 호출 시 페이지 데이터가 불완전하게 처리될 경우 발생하는 취약점입니다. 이로 인해 rq_pages 배열이 오버런되어 rq_respages 및 rq_next_page 포인터와 같은 후속 필드를 손상시킬 수 있습니다.
💡 쉬운 설명
파일 데이터를 나누어 읽는 과정에서 이미 읽은 데이터를 중복해서 기록하여 메모리 영역을 침범하는 오류입니다. 이 오류를 이용하면 시스템의 중요한 정보를 망가뜨리거나 제어권을 탈취할 수 있습니다.
🇺🇸 원문 (English)
In the Linux kernel, the following vulnerability has been resolved:
nfsd: don't replace page in rq_pages if it's a continuation of last page
The splice read calls nfsd_splice_actor to put the pages containing file
data into the svc_rqst->rq_pages array. It's possible however to get a
splice result that only has a partial page at the end, if (e.g.) the
filesystem hands back a short read that doesn't cover the whole page.
nfsd_splice_actor will plop the partial page into its rq_pages array and
return. Then later, when nfsd_splice_actor is called again, the
remainder of the page may end up being filled out. At this point,
nfsd_splice_actor will put the page into the array _again_ corrupting
the reply. If this is done enough times, rq_next_page will overrun the
array and corrupt the trailing fields -- the rq_respages and
rq_next_page pointers themselves.
If we've already added the page to the array in the last pass, don't add
it to the array a second time when dealing with a splice continuation.
This was originally handled properly in nfsd_splice_actor, but commit
91e23b1c3982 ("NFSD: Clean up nfsd_splice_actor()") removed the check
for it.
📍 영향받는 시스템
Linux Kernel (nfsd 모듈을 사용하는 시스템)
⚔️ 공격 벡터
조작된 splice read 요청을 통해 nfsd 서비스의 메모리 오버런 유도
🛡️ 대응 방법
Linux 커널을 최신 보안 패치가 적용된 버전으로 업데이트
🔧 검증 코드
출력된 커널 버전이 해당 취약점이 해결된 패치 버전 이후인지 확인