🇰🇷 한글 설명
Linux 커널의 net/sched: act_ct 모듈에서 nf_connlabels 참조 카운트가 해제되지 않는 메모리 누수 취약점이 발견되었습니다. 특정 오류 경로에서 nf_connlabels_put() 호출을 건너뛰어 참조 카운트가 계속 증가하게 됩니다. 이로 인해 unprivileged user namespace를 사용하는 사용자가 CAP_NET_ADMIN 권한을 가질 경우 메모리 누수를 유발할 수 있습니다.
💡 쉬운 설명
리눅스 시스템의 네트워크 설정 과정에서 오류가 발생할 때, 사용했던 메모리 자원을 제대로 반환하지 않고 버리는 문제가 있습니다. 공격자가 이 과정을 반복하면 시스템의 메모리가 조금씩 낭비되어 결국 시스템 성능 저하나 중단이 발생할 수 있습니다.
🇺🇸 원문 (English)
In the Linux kernel, the following vulnerability has been resolved:
net/sched: act_ct: fix nf_connlabels leak on two error paths
tcf_ct_fill_params() calls nf_connlabels_get() (setting put_labels) when
TCA_CT_LABELS is present, but two later error sites use a bare return
instead of "goto err", skipping the err: nf_connlabels_put() cleanup.
They also precede the "p->put_labels = put_labels" assignment, so the
tcf_ct_params_free() fallback does not release the count either. Each
failed RTM_NEWACTION on these paths leaks one nf_connlabels reference:
net->ct.labels_used is incremented and never released. The action is
reachable with CAP_NET_ADMIN over the netns, i.e. from an unprivileged
user namespace on default-userns kernels.
Impact: an unprivileged user with CAP_NET_ADMIN over a network namespace
(e.g. via user namespaces) leaks one nf_connlabels reference per failed
RTM_NEWACTION on the two error paths; net->ct.labels_used is never
released.
The err: label is safe to reach from both sites: p->tmpl is still NULL
there (kzalloc'd, not yet assigned) and nf_ct_put(NULL) is a no-op, so
no inline release is needed.
📍 영향받는 시스템
Linux kernel (net/sched: act_ct 관련 모듈이 포함된 버전)
⚔️ 공격 벡터
사용자 네임스페이스를 통해 CAP_NET_ADMIN 권한을 획득한 사용자가 의도적으로 실패하는 RTM_NEWACTION 요청을 반복 전송
🛡️ 대응 방법
Linux 커널을 최신 보안 패치가 적용된 버전으로 업데이트하여 act_ct의 오류 처리 로직 수정 적용
🔧 검증 코드
출력된 커널 버전이 해당 취약점이 수정된 패치 버전 이후인지 확인하십시오.