🇰🇷 한글 설명
Linux 커널의 OCFS2 파일 시스템에서 i_size는 0보다 크지만 할당된 클러스터가 없는 잘못된 구조의 dinode를 처리할 때 발생하는 취약점입니다. 이 취약점은 조작된 디렉토리 dinode를 통해 파일 시스템 탐색 과정에서 무한 루프나 오류를 유발할 수 있습니다.
💡 쉬운 설명
파일의 크기는 큰데 실제 저장 공간은 할당되지 않은 '가짜 파일 정보'를 시스템이 잘못 읽어 들여 문제가 생길 수 있습니다. 공격자가 이를 악용하면 시스템이 파일을 읽는 과정에서 멈추거나 오류가 발생할 수 있습니다.
🇺🇸 원문 (English)
In the Linux kernel, the following vulnerability has been resolved:
ocfs2: reject non-inline dinodes with i_size and zero i_clusters
On a volume mounted without OCFS2_FEATURE_INCOMPAT_SPARSE_ALLOC, a
non-inline regular file with non-zero i_size and zero i_clusters is
structurally malformed: the extent map declares no allocated clusters yet
the size header claims content exists. Keep rejecting that shape, but
express it through a shared predicate so the same invariant is available
to normal inode reads and online filecheck.
The same zero-cluster shape is also malformed for non-inline directories.
ocfs2 directory growth allocates backing storage before advancing i_size,
and ocfs2_dir_foreach_blk_el() later walks until ctx->pos reaches
i_size_read(inode). A forged directory dinode with a huge i_size and no
clusters would repeatedly fail on holes while advancing through the
claimed size.
Sparse regular files remain exempt: on sparse-alloc volumes, truncate can
legitimately grow i_size without allocating clusters. System inodes and
inline-data dinodes also retain their separate storage rules.
Mirror the check in ocfs2_filecheck_validate_inode_block() as well.
filecheck reports through its own error namespace, so malformed
size/cluster state is logged as a filecheck invalid-inode result rather
than via ocfs2_error(), but it must not proceed into
ocfs2_populate_inode().
📍 영향받는 시스템
OCFS2 기능을 사용하는 Linux 커널 (OCFS2_FEATURE_INCOMPAT_SPARSE_ALLOC 미사용 볼륨)
⚔️ 공격 벡터
조작된 구조를 가진 OCFS2 파일 시스템의 dinode(파일/디렉토리 정보)를 마운트하거나 읽기 시도
🛡️ 대응 방법
Linux 커널을 최신 보안 패치가 적용된 버전으로 업데이트하십시오.
🔧 검증 코드
출력된 커널 버전이 해당 취약점이 해결된 패치 버전 이후인지 확인하십시오.