🔍 CVE-2022-50555

7.8
CVSS Score
HIGH
2025-10-07
2026-08-04 10:18
✅ 완료

🇰🇷 한글 설명

Linux 커널의 TIPC 프로토콜 구현 중 tipc_topsrv_accept 함수에서 NULL 포인터 역참조 취약점이 발견되었습니다. tipc_topsrv_stop() 호출 시 listener가 NULL로 설정될 수 있음에도 불구하고, tipc_topsrv_accept 워커가 이를 계속 참조하여 시스템 충돌을 유발할 수 있습니다.

💡 쉬운 설명

리눅스 운영체제의 특정 통신 기능(TIPC)이 종료되는 과정에서, 이미 사라진 연결 정보를 참조하려고 시도하여 시스템이 멈추거나 충돌할 수 있는 문제입니다. 이는 프로그램이 존재하지 않는 주소를 읽으려 할 때 발생하는 전형적인 오류입니다.

🇺🇸 원문 (English)

In the Linux kernel, the following vulnerability has been resolved: tipc: fix a null-ptr-deref in tipc_topsrv_accept syzbot found a crash in tipc_topsrv_accept: KASAN: null-ptr-deref in range [0x0000000000000008-0x000000000000000f] Workqueue: tipc_rcv tipc_topsrv_accept RIP: 0010:kernel_accept+0x22d/0x350 net/socket.c:3487 Call Trace: <TASK> tipc_topsrv_accept+0x197/0x280 net/tipc/topsrv.c:460 process_one_work+0x991/0x1610 kernel/workqueue.c:2289 worker_thread+0x665/0x1080 kernel/workqueue.c:2436 kthread+0x2e4/0x3a0 kernel/kthread.c:376 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:306 It was caused by srv->listener that might be set to null by tipc_topsrv_stop() in net .exit whereas it's still used in tipc_topsrv_accept() worker. srv->listener is protected by srv->idr_lock in tipc_topsrv_stop(), so add a check for srv->listener under srv->idr_lock in tipc_topsrv_accept() to avoid the null-ptr-deref. To ensure the lsock is not released during the tipc_topsrv_accept(), move sock_release() after tipc_topsrv_work_stop() where it's waiting until the tipc_topsrv_accept worker to be done. Note that sk_callback_lock is used to protect sk->sk_user_data instead of srv->listener, and it should check srv in tipc_topsrv_listener_data_ready() instead. This also ensures that no more tipc_topsrv_accept worker will be started after tipc_conn_close() is called in tipc_topsrv_stop() where it sets sk->sk_user_data to null.

📍 영향받는 시스템

TIPC 프로토콜이 활성화된 Linux 커널 버전

⚔️ 공격 벡터

로컬 또는 네트워크를 통해 TIPC 프로토콜을 사용하는 환경에서 특정 시퀀스의 패킷을 전송하여 커널 패닉 유도

🛡️ 대응 방법

TIPC 관련 커널 패치를 적용하여 tipc_topsrv_accept 내 listener NULL 체크 로직을 추가하고 리소스 해제 순서를 조정해야 함

🔧 검증 코드

현재 실행 중인 커널 버전을 확인하여 해당 취약점이 해결된 패치 버전인지 확인합니다.

Shell / Script
uname -r

📊 CVSS Vector String

CVSS Vector
CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H

💻 영향받는 소프트웨어

Linux Kernel