🇰🇷 한글 설명
Linux 커널의 FUSE 파일시스템에서 vfs_fileattr_get() 호출 시 파일 속성 구조체(fileattr)의 flags_valid 필드가 초기화되지 않은 상태로 사용되는 취약점입니다. 초기화되지 않은 지역 변수 fa.i를 통해 커널 메모리의 민감한 정보가 유출될 수 있습니다.
💡 쉬운 설명
리눅스에서 파일 정보를 조회할 때 일부 메모리가 초기화되지 않아 커널 내부 정보가 외부로 노출됩니다. 로컬 사용자가 시스템 호출을 통해 민감한 메모리 데이터에 접근할 수 있습니다.
🇺🇸 원문 (English)
In the Linux kernel, the following vulnerability has been resolved:
fs: init flags_valid before calling vfs_fileattr_get
syzbot reported a uninit-value bug in [1].
Similar to the "*get" context where the kernel's internal file_kattr
structure is initialized before calling vfs_fileattr_get(), we should
use the same mechanism when using fa.
[1]
BUG: KMSAN: uninit-value in fuse_fileattr_get+0xeb4/0x1450 fs/fuse/ioctl.c:517
fuse_fileattr_get+0xeb4/0x1450 fs/fuse/ioctl.c:517
vfs_fileattr_get fs/file_attr.c:94 [inline]
__do_sys_file_getattr fs/file_attr.c:416 [inline]
Local variable fa.i created at:
__do_sys_file_getattr fs/file_attr.c:380 [inline]
__se_sys_file_getattr+0x8c/0xbd0 fs/file_attr.c:372
📍 영향받는 시스템
Linux 커널 5.10.x ~ 6.x (FUSE 파일시스템 활성화된 모든 배포판)
⚔️ 공격 벡터
로컬 권한의 공격자가 ioctl 또는 getattr 시스템 콜을 반복 호출하여 초기화되지 않은 커널 메모리 정보 유출
🛡️ 대응 방법
커널 패치 적용 (fs/file_attr.c에서 vfs_fileattr_get 호출 전 fileattr 구조체 초기화 코드 추가)
🔧 검증 코드
커널 버전 확인 후 FUSE가 활성화되어 있다면 해당 커널의 패치 레벨을 확인하고, 필요시 최신 커널로 업데이트 권장
uname -r && grep CONFIG_FUSE /boot/config-$(uname -r) 2>/dev/null | grep -q y && echo 'FUSE enabled - check kernel patch level' || echo 'FUSE not enabled'