🇰🇷 한글 설명
Linux 커널의 AF_UNIX 가비지 컬렉션(GC) 과정에서 scc_index가 제대로 초기화되지 않아 발생하는 취약점입니다. 이로 인해 살아있는 소켓이 잘못된 SCC(강결합 컴포넌트)로 분류되어 가비지 컬렉션에 의해 조기 해제될 수 있습니다.
💡 쉬운 설명
컴퓨터가 사용 중인 중요한 연결 통로를 실수로 '더 이상 필요 없는 것'으로 착각하여 강제로 끊어버릴 수 있는 오류입니다. 이 과정에서 시스템의 안정성이 떨어지거나 보안 문제가 발생할 수 있습니다.
🇺🇸 원문 (English)
In the Linux kernel, the following vulnerability has been resolved:
af_unix: Initialise scc_index in unix_add_edge().
Quang Le reported that the AF_UNIX GC could garbage-collect a
receive queue of an alive in-flight socket, with a nice repro.
The repro consists of three stages.
1)
1-a. Create a single cyclic reference with many sockets
1-b. close() all sockets
1-c. Trigger GC
2)
2-a. Pass sk-A to an embryo sk-B
2-b. Pass sk-X to sk-X
2-c. Trigger GC
3)
3-a. accept() the embryo sk-B
3-b. Pass sk-B to sk-C
3-c. close() the in-flight sk-A
3-d. Trigger GC
As of 2-c, sk-A and sk-X are linked to unix_unvisited_vertices,
and unix_walk_scc() groups them into two different SCCs:
unix_sk(sk-A)->vertex->scc_index = 2 (UNIX_VERTEX_INDEX_START)
unix_sk(sk-X)->vertex->scc_index = 3
Once GC completes, unix_graph_grouped is set to true.
Also, unix_graph_maybe_cyclic is set to true due to sk-X's
cyclic self-reference, which makes close() trigger GC.
At 3-b, unix_add_edge() allocates unix_sk(sk-B)->vertex and
links it to unix_unvisited_vertices.
unix_update_graph() is called at 3-a. and 3-b., but neither
unix_graph_grouped nor unix_graph_maybe_cyclic is changed
because both sk-B's listener and sk-C are not in-flight.
3-c decrements sk-A's file refcnt to 1.
Since unix_graph_grouped is true at 3-d, unix_walk_scc_fast()
is finally called and iterates 3 sockets sk-A, sk-B, and sk-X:
sk-A -> sk-B (-> sk-C)
sk-X -> sk-X
This is totally fine. All of them are not yet close()d and
should be grouped into different SCCs.
However, unix_vertex_dead() misjudges that sk-A and sk-B are
in the same SCC and sk-A is dead.
unix_sk(sk-A)->scc_index == unix_sk(sk-B)->scc_index <-- Wrong!
&&
sk-A's file refcnt == unix_sk(sk-A)->vertex->out_degree
^-- 1 in-flight count for sk-B
-> sk-A is dead !?
The problem is that unix_add_edge() does not initialise scc_index.
Stage 1) is used for heap spraying, making a newly allocated
vertex have vertex->scc_index == 2 (UNIX_VERTEX_INDEX_START)
set by unix_walk_scc() at 1-c.
Let's track the max SCC index from the previous unix_walk_scc()
call and assign the max + 1 to a new vertex's scc_index.
This way, we can continue to avoid Tarjan's algorithm while
preventing misjudgments.
📍 영향받는 시스템
Linux Kernel (AF_UNIX 관련 모듈 사용 시스템)
⚔️ 공격 벡터
특수하게 조작된 소켓 참조 구조를 생성하여 가비지 컬렉션을 유도하는 방식
🛡️ 대응 방법
Linux 커널을 최신 보안 패치가 적용된 버전으로 업데이트하여 unix_add_edge() 내 scc_index 초기화 로직을 적용해야 합니다.
🔧 검증 코드
출력된 커널 버전이 해당 취약점이 수정된 패치 버전 이후인지 확인합니다.
🇰🇷 KISA(한국인터넷진흥원) 보안 권고
이 CVE에 대한 한국 공식 권고 (1건)
삼성전자 제품 보안 업데이트 권고
P4
📅 2026-06-02 · sec_notice
삼성전자 갤럭시 모바일 기기에서 원격 코드 실행, 권한 상승, 정보 노출을 유발할 수 있는 다수의 보안 취약점이 발견되었습니다. Android 14, 15, 16 버전을 사용하는 삼성 갤럭시 사용자 및 Exynos 탑재 기기 사용자는 보안 업데이트를 통해 최신 버전(SMR Jun-2026 Release 1 이상)으로 즉시 업데이트해야 합니다.