xfs: fix another iunlink infinite loop bug in online fsck
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
| No fix yet |
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
xfs: fix another iunlink infinite loop bug in online fsck
xrep_iunlink_resolve_bucket is supposed to reconstruct as much of the incore prev and next unlinked list pointers based on what it finds on disk and in memory before we move on to relinking the truly lost inodes back into the unlinked list. However, it's still vulnerable to infinite loops that come in via the next_unlinked pointers.
Fix this problem by remembering which inodes we've already seen and checking new agino pointers against that. If a bit is already set, either this is a loop or the inode has nonzero link count. We'll deal with the second case in a subsequent patch.
From the CVE record · Linux
The Linux kernel's XFS online fsck can enter an infinite loop while reconstructing unlinked inode lists if next_unlinked pointers form a loop. The input does not specify whether an attacker can trigger this or what access or user interaction would be required.
Engineers running Linux kernels with XFS online fsck should check their deployments; affected versions were not provided.