🇰🇷 한글 설명
Linux 커널의 XFS 파일 시스템에서 xfs_trans_roll 함수 호출 시 NOFS 컨텍스트가 조건 없이 복구되지 않는 취약점이 발견되었습니다. __xfs_trans_commit() 실패 시 NOFS 보호 기능이 해제된 상태로 남아 있어, xfs_nondir_ilock_class와 fs_reclaim 간의 순환 잠금(Circular Lock) 의존성을 유발할 수 있습니다.
💡 쉬운 설명
파일 시스템 작업 중 오류가 발생하면 시스템이 자원을 관리하는 규칙이 꼬여버리는 문제가 있습니다. 이로 인해 시스템이 서로의 자원을 기다리며 멈춰버리는 '데드락(Deadlock)' 현상이 발생할 수 있습니다.
🇺🇸 원문 (English)
In the Linux kernel, the following vulnerability has been resolved:
xfs: restore nofs context unconditionally in xfs_trans_roll
When __xfs_trans_commit() fails in xfs_trans_roll(), the NOFS context
is cleared but only restored in the success path. This leaves the
error path without nofs protection, causing a circular lock dependency
between xfs_nondir_ilock_class and fs_reclaim:
CPU0 CPU1
---- ----
lock(&xfs_nondir_ilock_class);
lock(fs_reclaim);
lock(&xfs_nondir_ilock_class);
lock(fs_reclaim);
Fix this by moving xfs_trans_set_context() before the error check so
that nofs context is always restored on the new transaction.
📍 영향받는 시스템
XFS 파일 시스템을 사용하는 Linux 커널 버전
⚔️ 공격 벡터
로컬 공격자가 파일 시스템 작업 중 의도적으로 오류를 유발하여 시스템 데드락 유도
🛡️ 대응 방법
XFS 관련 패치가 적용된 최신 Linux 커널로 업데이트
🔧 검증 코드
출력된 커널 버전이 해당 취약점이 수정된 최신 패치 버전인지 확인