🇰🇷 한글 설명
Linux 커널의 svcrdma 구성 요소에서 RDMA 주소 변경 시 새로운 리스너 할당에 실패할 경우, 기존의 cm_id를 해제하지 않고 유지하여 발생하는 취약점입니다. 이로 인해 이후 sc_cm_id를 참조할 때 이미 해제된 메모리에 접근하는 Use-After-Free(UAF) 오류가 발생할 수 있습니다.
💡 쉬운 설명
네트워크 주소가 바뀔 때 새로운 연결 통로를 만드는 과정에서 오류가 나면, 이미 사라진 통로를 다시 사용하려고 시도하다가 시스템이 충돌하거나 보안 문제가 생길 수 있습니다.
🇺🇸 원문 (English)
In the Linux kernel, the following vulnerability has been resolved:
svcrdma: Clear sc_cm_id when ADDR_CHANGE replacement fails
When svc_rdma_listen_handler() handles RDMA_CM_EVENT_ADDR_CHANGE,
it creates a replacement listener cm_id and returns 1, telling
the CM core to destroy the old one. If the replacement allocation
fails, sc_cm_id still points at the old cm_id that the CM core is
about to destroy. Any subsequent dereference of sc_cm_id --
such as svc_rdma_detach()'s rdma_disconnect() call -- is a
use-after-free.
NULL sc_cm_id on the failure path and guard svc_rdma_detach()'s
rdma_disconnect() call against NULL so that the listener can
be torn down safely when the server shuts down.
📍 영향받는 시스템
Linux kernel (svcrdma 구성 요소가 포함된 버전)
⚔️ 공격 벡터
RDMA 주소 변경 이벤트(RDMA_CM_EVENT_ADDR_CHANGE)를 유도하여 메모리 할당 실패를 일으킴으로써 Use-After-Free 유발
🛡️ 대응 방법
Linux 커널을 최신 보안 패치가 적용된 버전으로 업데이트하여 sc_cm_id에 대한 NULL 체크 및 안전한 해제 로직을 적용해야 함
🔧 검증 코드
출력된 커널 버전이 해당 취약점이 수정된 패치 버전 이후인지 확인