🇰🇷 한글 설명
Linux 커널의 pinctrl: single 구성 요소에서 pcs_add_gpio_func() 함수 호출 시 참조 횟수(refcount) 누수가 발생하는 취약점입니다. of_parse_phandle_with_args() 함수가 반환하는 device_node 포인터에 대한 참조를 적절히 해제하지 않아 메모리 자원이 지속적으로 소모됩니다.
💡 쉬운 설명
컴퓨터의 핵심 운영체제인 리눅스에서 특정 작업을 반복할 때마다 사용한 메모리를 제대로 돌려주지 않는 버그가 발견되었습니다. 이 문제가 계속되면 시스템의 메모리가 점차 부족해져 성능이 떨어지거나 시스템이 멈출 수 있습니다.
🇺🇸 원문 (English)
In the Linux kernel, the following vulnerability has been resolved:
pinctrl: single: fix refcount leak in pcs_add_gpio_func()
of_parse_phandle_with_args() returns a device_node pointer with refcount
incremented in gpiospec.np. The loop iterates through all phandles but
never releases the reference, causing a refcount leak on each iteration.
Add of_node_put() calls to release the reference after extracting the
needed arguments and on the error path when devm_kzalloc() fails.
This bug was detected by our static analysis tool and verified by my
code review.
📍 영향받는 시스템
pinctrl: single 모듈을 사용하는 Linux 커널 버전
⚔️ 공격 벡터
직접적인 공격보다는 시스템의 가용성을 저하시키는 서비스 거부(DoS) 형태의 자원 고갈로 이어질 수 있음
🛡️ 대응 방법
of_node_put() 호출이 포함된 최신 Linux 커널 패치 적용
🔧 검증 코드
출력된 커널 버전이 해당 취약점이 수정된 패치 버전 이후인지 확인