🇰🇷 한글 설명
Linux 커널의 net/smc 구성 요소에서 링크 그룹 종료 시 소켓 사용 후 해제(Use-After-Free) 취약점이 발견되었습니다. 연결 종료 과정에서 잠금(lock)을 해제하는 시점과 소켓 참조를 확보하는 시점 사이에 경쟁 상태(Race Condition)가 발생하여 메모리 오류를 유발할 수 있습니다.
💡 쉬운 설명
컴퓨터가 네트워크 연결을 정리하는 도중에 다른 작업이 동시에 연결을 끊어버려, 이미 사라진 메모리 공간을 다시 사용하려고 시도하는 문제입니다. 이로 인해 시스템이 멈추거나 보안 공격에 악용될 수 있습니다.
🇺🇸 원문 (English)
In the Linux kernel, the following vulnerability has been resolved:
net/smc: fix socket use-after-free during link group termination
__smc_lgr_terminate() drops conns_lock after finding a connection in
lgr->conns_all, but before taking a reference on its socket. The connection
is embedded in the socket, and its registration reference protects it only
while the connection remains in the tree.
A concurrent close can unregister the connection and drop that reference,
freeing the socket before the termination worker reaches sock_hold().
The race is reachable when close overlaps link group termination.
Local stress testing reproduced the use-after-free and KASAN reported:
BUG: KASAN: slab-use-after-free in __smc_lgr_terminate.part.0 [smc]
Write of size 4 by task kworker/3:3
Workqueue: events smc_lgr_terminate_work [smc]
__smc_lgr_terminate.part.0 [smc]
The socket was allocated by smc_create(), freed through
slab_free_after_rcu_debug(), and was followed by:
refcount_t: addition on 0; use-after-free.
__smc_lgr_terminate.part.0 [smc]
Take the socket reference while conns_lock still protects the tree entry.
The unregister path then cannot drop the last reference until termination
has finished using the socket.
📍 영향받는 시스템
Linux kernel (net/smc 모듈을 사용하는 시스템)
⚔️ 공격 벡터
로컬 환경에서 링크 그룹 종료와 연결 종료를 동시에 유도하는 경쟁 상태 공격
🛡️ 대응 방법
Linux 커널을 최신 보안 패치가 적용된 버전으로 업데이트하십시오.
🔧 검증 코드
출력된 커널 버전을 확인하여 해당 취약점이 해결된 최신 패치 버전인지 확인하십시오.