🇰🇷 한글 설명
Linux 커널의 RDMA/umem 구성 요소에서 오류 발생 시 dma_buf_unpin이 중복으로 호출되는 취약점이 발견되었습니다. ib_umem_dmabuf_get_pinned_with_dma_device 함수에서 매핑 실패 시 즉시 unpin을 수행하지만, 이후 해제 과정에서 다시 unpin이 호출되어 문제가 발생합니다.
💡 쉬운 설명
컴퓨터 메모리를 관리하는 과정에서 이미 해제된 메모리를 다시 해제하려고 시도하는 오류가 있습니다. 이로 인해 시스템이 불안정해지거나 예기치 않게 종료될 수 있습니다.
🇺🇸 원문 (English)
In the Linux kernel, the following vulnerability has been resolved:
RDMA/umem: Fix double dma_buf_unpin in failure path
In ib_umem_dmabuf_get_pinned_with_dma_device(), the call to
ib_umem_dmabuf_map_pages() can fail. If this occurs, the dmabuf
is immediately unpinned but the umem_dmabuf->pinned flag is still
set. Then, when ib_umem_release() is called, it calls
ib_umem_dmabuf_revoke() which will call dma_buf_unpin() again.
Fix this by removing the immediate unpin upon failure and just let
the ib_umem_release/revoke path handle it. This also ensures the
proper unmap-unpin unwind ordering if the dmabuf_map_pages call
happened to fail due to dma_resv_wait_timeout (and therefore has
a non-NULL umem_dmabuf->sgt).
📍 영향받는 시스템
RDMA 기능을 사용하는 Linux 커널 버전
⚔️ 공격 벡터
특정 조건에서 RDMA 메모리 매핑 실패를 유도하여 커널 패닉 또는 시스템 불안정 유발
🛡️ 대응 방법
해당 취약점이 수정된 최신 Linux 커널 버전으로 업데이트
🔧 검증 코드
출력된 커널 버전이 해당 패치가 적용된 보안 업데이트 버전인지 확인