freebsd-skq/sbin/newfs
Kirk McKusick 8f829a5cf0 Continuing efforts to provide hardening of FFS. This change adds a
check hash to the filesystem inodes. Access attempts to files
associated with an inode with an invalid check hash will fail with
EINVAL (Invalid argument). Access is reestablished after an fsck
is run to find and validate the inodes with invalid check-hashes.
This check avoids a class of filesystem panics related to corrupted
inodes. The hash is done using crc32c.

Note this check-hash is for the inode itself and not any of its
indirect blocks. Check-hash validation may be extended to also
cover indirect block pointers, but that will be a separate (and
more costly) feature.

Check hashes are added only to UFS2 and not to UFS1 as UFS1 is
primarily used in embedded systems with small memories and low-powered
processors which need as light-weight a filesystem as possible.

Reviewed by:  kib
Tested by:    Peter Holm
Sponsored by: Netflix
2018-12-11 22:14:37 +00:00
..
Makefile sbin: normalize paths using SRCTOP-relative paths or :H when possible 2017-03-04 11:33:01 +00:00
Makefile.depend DIRDEPS_BUILD: Update dependencies. 2017-10-31 00:07:04 +00:00
mkfs.c Continuing efforts to provide hardening of FFS. This change adds a 2018-12-11 22:14:37 +00:00
newfs.8 Bump date for today's commit. 2017-07-07 16:58:40 +00:00
newfs.c newfs: clean up warnings 2018-06-24 05:40:42 +00:00
newfs.h General further adoption of SPDX licensing ID tags. 2017-11-20 19:49:47 +00:00
ref.test
runtest00.sh
runtest01.sh