🇰🇷 한글 설명
Linux 커널의 orangefs 모듈에서 kmemleak 취약점이 발견되었습니다. orangefs 모듈을 삽입하거나 제거할 때 orangefs_{kernel,client}_debug_init() 함수를 통해 메모리 누수가 발생합니다.
💡 쉬운 설명
컴퓨터의 메모리를 사용하는 프로그램이 종료될 때 사용했던 메모리를 제대로 돌려주지 않는 문제입니다. 이 현상이 반복되면 시스템의 메모리가 부족해져 성능이 떨어지거나 멈출 수 있습니다.
🇺🇸 원문 (English)
In the Linux kernel, the following vulnerability has been resolved:
orangefs: Fix kmemleak in orangefs_{kernel,client}_debug_init()
When insert and remove the orangefs module, there are memory leaked
as below:
unreferenced object 0xffff88816b0cc000 (size 2048):
comm "insmod", pid 783, jiffies 4294813439 (age 65.512s)
hex dump (first 32 bytes):
6e 6f 6e 65 0a 00 00 00 00 00 00 00 00 00 00 00 none............
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
backtrace:
[<0000000031ab7788>] kmalloc_trace+0x27/0xa0
[<000000005b405fee>] orangefs_debugfs_init.cold+0xaf/0x17f
[<00000000e5a0085b>] 0xffffffffa02780f9
[<000000004232d9f7>] do_one_initcall+0x87/0x2a0
[<0000000054f22384>] do_init_module+0xdf/0x320
[<000000003263bdea>] load_module+0x2f98/0x3330
[<0000000052cd4153>] __do_sys_finit_module+0x113/0x1b0
[<00000000250ae02b>] do_syscall_64+0x35/0x80
[<00000000f11c03c7>] entry_SYSCALL_64_after_hwframe+0x46/0xb0
Use the golbal variable as the buffer rather than dynamic allocate to
slove the problem.
📍 영향받는 시스템
orangefs 모듈을 사용하는 Linux 커널 시스템
⚔️ 공격 벡터
모듈의 반복적인 로드 및 언로드(insmod/rmmod)를 통한 메모리 고갈 유도
🛡️ 대응 방법
orangefs 모듈의 디버그 초기화 시 동적 할당 대신 전역 변수를 사용하도록 커널 패치 적용
🔧 검증 코드
orangefs 모듈이 로드되어 있는지 확인하고, dmesg 로그에서 kmemleak 관련 메모리 누수 경고가 있는지 확인합니다.
lsmod | grep orangefs && dmesg | grep -i kmemleak