Re: [Syzkaller & bisect] There is BUG: unable to handle kernel NULL pointer dereference in xfs_extent_free_diff_items in v6.4-rc3

Eric Biggers
2023-05-23T23:46:17Z

On Wed, May 24, 2023 at 08:16:58AM +1000, Dave Chinner wrote:
> config XFS_SUPPORT_V4
> bool "Support deprecated V4 (crc=0) format"
> depends on XFS_FS
> default y
> help
> The V4 filesystem format lacks certain features that are supported
> by the V5 format, such as metadata checksumming, strengthened
> metadata verification, and the ability to store timestamps past the
> year 2038. Because of this, the V4 format is deprecated. All users
> should upgrade by backing up their files, reformatting, and restoring
> from the backup.
>
> Administrators and users can detect a V4 filesystem by running
> xfs_info against a filesystem mountpoint and checking for a string
> beginning with "crc=". If the string "crc=0" is found, the
> filesystem is a V4 filesystem. If no such string is found, please
> upgrade xfsprogs to the latest version and try again.
>
> This option will become default N in September 2025. Support for the
> V4 format will be removed entirely in September 2030. Distributors
> can say N here to withdraw support earlier.
>
> To continue supporting the old V4 format (crc=0), say Y.
> To close off an attack surface, say N.
>
> This was added almost 3 years ago in mid-2020. We're more than half
> way through the deprecation period and then we're going to turn off
> v4 support by default. At this point, nobody should be using v4
> filesystems in new production systems, and those that are should be
> preparing for upstream and distro support to be withdraw in the next
> couple of years...

Great to see that this exists now and there is a specific deprecation plan!

> > Then you could just tell the people fuzzing XFS filesystem images
> > that they need to use that option. That would save everyone a lot of time.
> > (To be clear, I'm not arguing for the XFS policy on v4 filesystems being right
> > or wrong; that's really not something I'd like to get into again... I'm just
> > saying that if that's indeed your policy, this is what you should do.)
>
> It should be obvious by now that we've already done this. 3 years
> ago, in fact. And yet we are still having the same problems. Maybe
> this helps you understand the level of frustration we have with all
> the people running fuzzing bots out there....

I don't see evidence that this actually happened, though perhaps we are not
looking in the same places. https://lore.kernel.org/all/?q=XFS_SUPPORT_V4
brings up little except the original patch thread, nor did
https://github.com/search?q=XFS_SUPPORT_V4&type=issues find anything.

Anyway, I took 3 minutes to file an issue in the syzkaller repo
(https://github.com/google/syzkaller/issues/3918), so at least this should get
resolved for syzbot soon.

- Eric