Age | Commit message (Collapse) | Author | |
---|---|---|---|
2009-05-29 | catch funny values of cg_initediblk; make fsck_ffs more robust | Otto Moerbeek | |
against forms of cg header corruption as experienced by todd@; ok millert@ | |||
2008-12-29 | Some forms of inode corruption can make remsize and thus isize go | Otto Moerbeek | |
negative and cause SEGVs. Handle this the same as an out of range blockno. ok jsg@ (also victim) pedro@ thib@ | |||
2008-11-09 | add missing header needed by getpagesize(). | Charles Longeau | |
ok millert@ | |||
2008-11-06 | Have called pass pagesize into FS_KERNMAXFILESIZE(), because there is no | Theo de Raadt | |
automatic symbol that has this information. PAGE_SIZE is simply not portable, or even fixed on some systems. ok otto | |||
2008-11-02 | check for the maximum file size to avoid some out-of-bounds accesses; | Otto Moerbeek | |
ok millert@ | |||
2008-06-10 | reduce mem usage by about 20% by packing state and type of an inode in a single | Otto Moerbeek | |
byte. Original diff by drahn@; twists by me; ok millert@ thib@ | |||
2008-06-10 | print sizeofs using %zu; ok joris@ | Otto Moerbeek | |
2008-06-09 | The new newfs(8) code causes alternate superblocks to end up in | Otto Moerbeek | |
different locations than before. Actually, the disklabel does not contain enough info to completely reconstruct the locations of all alternate sb's. So use a hardcoded list of all possible 1st alternate sb locations, but don't forget to verify against the label. ok millert@ thib@ | |||
2008-05-26 | reorg fields in structs inodesc and inoinfo to reduce size on some archs; from | Otto Moerbeek | |
mickey; ok millert@ | |||
2007-09-16 | Do not use DIP() as an lvalue; founc by pcc. ok millert@ ray@ | Otto Moerbeek | |
2007-07-17 | rmoev the macppc workaround, now that isset() and friends use expressions | Otto Moerbeek | |
that gcc likes better | |||
2007-07-04 | workaround for [daddr64_t] issue; worked on mostly by otto, wee bit by me | Theo de Raadt | |
2007-06-25 | Teach fsck_ffs about 64-bit block addresses. ok (and help) moritz@ pedro@ | Otto Moerbeek | |
2007-06-01 | ufs1_daddr_t cleanup, okay otto@ | Pedro Martelletto | |
2007-06-01 | Don't use cg.cg_niblk but fs.fs_ipg; the former has no meaning any more. | Otto Moerbeek | |
Fixes PR 5494; with pedro@; ok pedro@ millert@ | |||
2007-06-01 | convert ufs2_daddr_t -> daddr64_t for greater clarity; ok pedro otto thib | Theo de Raadt | |
2007-05-31 | convert to new .Dd format; | Jason McIntyre | |
2007-05-29 | Updated disklabel format to support larger disks and partitions. We | Otto Moerbeek | |
free room in struct partition by packing fragment size and fragments/block more tighlty and use the resulting space to make offset and size 48 bits. For the disk part we use spare fields in struct disklabel. Kernel converts in-mem copy of the on-disk label if needed, disklabel(8) writes new version. We are careful to only change fields not used by bootloaders. Conception of basic scheme by deraadt. ok deraadt@ krw@ | |||
2007-05-18 | Fix mismerge; remove statement without effect. OK otto@ pedro@ | Todd C. Miller | |
2007-05-11 | pass the right size arg to memset, otherwise we end up with a | Otto Moerbeek | |
partially initialized summary info struct. ok millert@ pedro@ | |||
2007-05-05 | Do not rely on fs_cpg; this is especially important for ffs2 which | Todd C. Miller | |
does not use fs_cpg at all. From FreeBSD. OK otto@ | |||
2007-04-23 | Remove 'cg_space' from 'struct cg'. Due to the alignment on 64-bit | Pedro Martelletto | |
architectures, CGSIZE() was returning something sligthly over one block. The 'new' fsck would round this value up to a fragment boundary, and end up trying to access memory beyond allocated space. From mickey@, okay pedro@, millert@ and otto@. | |||
2007-04-21 | use the correct size arg to memcmp when checking fs_cstotal. | Otto Moerbeek | |
now jmc does not use 8TB in /tmp anymore. ok pedro@ | |||
2007-04-18 | When trying to read the primary superblock, do not accidentially read | Otto Moerbeek | |
a ffs1 alternate sb at the primary ffs2 sb location. Use the same test as the kernel does. ok millert@ pedro@ | |||
2007-04-10 | Add support for checking ffs2 filesystems. From pedro@ based on | Todd C. Miller | |
the ufs2 changes in FreeBSD by Kirk Mckusick. | |||
2007-03-19 | be a tiny little bit more verbose when encoutering bad block or fragment | Otto Moerbeek | |
sizes; requested by mickey@ | |||
2007-03-19 | Add FFS2 fields to the superblock, change file system tools to keep | Pedro Martelletto | |
accessing FFS1 fields, okay art@, quite some testing by ckuethe@, simon@ and thib@, thanks. | |||
2007-03-18 | there's no way we're going to be able to handle illegal block or | Otto Moerbeek | |
fragment sizes, so just make those conditions fatal errors and tell the calling code to go look for alternate superblocks. ok millert@ | |||
2007-03-15 | Check for cg_irotor and cg_frotor being negative, okay millert@ deraadt@ | Pedro Martelletto | |
2007-02-16 | Fix a row of bugs in the code that computes the alternate superblock | Otto Moerbeek | |
locations based on the disklabel. - unit bug: disklabel size is in sectors, but superblock fs size is in fragments. - The disklabel contains the maximum superblock size, not the actual as used by newfs. - problem is that mkfs reduces track/sector and secors/track to make the cylindergroup fit in a fs block. In this case the values in the disklabel do not predict what's in the superblock. This fixes all these problems. It correctly predicts the location of all superblocks on all my filesystems I have online (sized between 100MB and 1000GB). Also tested with filesystems with different block and fragment sizes. Written this with a goto to make the diff easier to read. ok krw@ deraadt@ | |||
2007-02-13 | "Fix" a horrible signal handler. ckfini() breaks all the rules for | Otto Moerbeek | |
signal handlers, calling free() and not being reentrant. This commit fixes to most importamt problem (^C on the "MARK FILESYSTEM CLEAN?" question causes a double free), but actually SIGINT handling should be completely rewritten. ok millert@ deraadt@ | |||
2007-02-13 | Do some extra validation of the superblock, otherwise a corrupt | Otto Moerbeek | |
superblock might lead to crashes or other mishap. Now my fuzzed fs images no longer crash fsck_ffs. ok mickey@ pedro@ millert@ | |||
2007-02-12 | remsize must be signed to avoid wrapping around to some huge number. | Otto Moerbeek | |
Solves a case were fsck_ffs was causing a segv. If it didn't do that it would have mangled the filesystem later, very probably. Diff from FreeBSD; ok millert@ pedro@ | |||
2007-02-12 | detect truncation of block number, which can happen which trashed | Otto Moerbeek | |
inodes; ok pedro@ millert@ | |||
2007-02-12 | max partition letter is 'a' + MAXPARTITIONS - 1, not 'h'. ok (and | Otto Moerbeek | |
help) miod@ | |||
2007-02-09 | fix a fd leak that happens whe checking multiple file systems and some | Otto Moerbeek | |
of them are clean. ok pedro@ millert@ | |||
2007-02-08 | Plug some mem leaks that occur when checking multiple file systems in a | Otto Moerbeek | |
row. ok beck@ pedro@ millert@ | |||
2007-02-08 | A corrrup inode might lead to preposterous dir sizes. So check the | Otto Moerbeek | |
size to avoid a negative lastbn which might cause a segv or heap corruption. With help from mickey@; ok mickey@ pedro@ millert@ | |||
2007-01-24 | A reallocated root directory gets ownership of the fsck process. | Alexander Bluhm | |
If lost+found is created, it gets ownership of the root directory. ok pedro | |||
2006-04-27 | Avoid spurious 'summary information bad' warnings, okay tedu@ | Pedro Martelletto | |
2006-04-17 | more signal handler cleaning | Theo de Raadt | |
2006-04-17 | solve half of the signal race issues | Theo de Raadt | |
2006-04-17 | prettier code; ok pedro | Theo de Raadt | |
2006-04-17 | Remove "l:" from getopt(3) string, since the option was | Moritz Jodeit | |
removed long ago. From Steffen Wendzel. ok pedro@ | |||
2006-04-07 | fsck needs to unset FS_FLAGS_UPDATED if it changes the super block | Pedro Martelletto | |
2006-04-02 | use SEEK_* for lseek() | Theo de Raadt | |
2006-03-30 | when asking y or n, accept "F" which forces yes from the on. i have | Theo de Raadt | |
wished for this for 10+ year, but always forgotten to make the change after cleaning up a nasty file system; ok pedro millert | |||
2006-03-22 | earlier asprintf diff caused malloc in signal handler. clarify the | Theo de Raadt | |
code a bit more so that this mistake will not be done again | |||
2006-03-20 | NetBSD Coverity CID 2074: Fix memory leak. | David Hill | |
ok deraadt@ | |||
2006-03-12 | use asprintf instead of a static buffer; dhill, tested by pedro | Theo de Raadt | |