e2fsprogs/e2fsck
Wang Shilong 101e73e99c e2fsck: fix use after free in calculate_tree()
The problem is alloc_blocks() will call get_next_block() which might
reallocate outdir->buf, and memory address could be changed after
this.  To fix this, pointers that point into outdir->buf, such as
int_limit and root need to be recaulated based on the new starting
address of outdir->buf.

[ Changed to correctly recalculate int_limit, and to optimize how we
  reallocate outdir->buf.  -TYT ]

Signed-off-by: Wang Shilong <wshilong@ddn.com>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
2020-01-01 13:41:34 -05:00
..
Android.bp AOSP: E2fsprogs: fix ODR issue 2019-02-07 22:41:25 -05:00
badblocks.c e2fsck: fix memory leak on error path in read_bad_blocks_files() 2014-01-07 09:10:24 -05:00
CHANGES Fix historic typos in changelogs and release notes 2017-10-15 23:19:22 -04:00
dirinfo.c e2fsck: add error-checking when unlink tdb file for dir_info 2018-06-24 14:00:14 -04:00
dx_dirinfo.c libext2fs: support encoding when calculating dx hashes 2018-12-02 23:58:50 -05:00
e2fsck.8.in AOSP: e2fsck: imply -f when using -E unshare_blocks 2018-06-21 10:14:47 -04:00
e2fsck.c e2fsck: set E2FSCK_TIME correctly on a 32-bit arch with a 64-bit time_t 2019-07-24 22:25:11 -04:00
e2fsck.conf.5.in e2fsck: add support for saving the problem code log 2019-05-06 10:15:41 -04:00
e2fsck.h e2fsck: add support for saving the problem code log 2019-05-06 10:15:41 -04:00
ea_refcount.c e2fsck: generalize ea_refcount 2017-07-04 23:53:59 -04:00
ehandler.c e2fsck: on read error, don't rewrite blocks past the end of the fs 2015-01-27 13:12:37 -05:00
emptydir.c Shorten compile commands run by the build system 2011-09-18 17:34:37 -04:00
extend.c Shorten compile commands run by the build system 2011-09-18 17:34:37 -04:00
extents.c ext2fs: add ext2fs_get_stat_i_blocks() function 2020-01-01 13:41:28 -05:00
flushb.c Shorten compile commands run by the build system 2011-09-18 17:34:37 -04:00
iscan.c debugfs, e2fsck: fix s_desc_size handling 2013-12-24 22:50:19 -05:00
jfs_user.h e2fsck: fix LTO type warnings 2018-08-08 21:23:59 -04:00
journal.c e2fsck: fix kernel compat functions to use kernel error return conventions 2018-07-04 00:18:30 -04:00
logfile.c e2fsck: add support for saving the problem code log 2019-05-06 10:15:41 -04:00
Makefile.in libext2fs: remove nls_* namespace contamination 2019-04-29 09:18:12 -04:00
message.c Merge branch 'maint' into next 2017-10-15 23:20:53 -04:00
mtrace.awk Many files: 1997-04-26 13:21:57 +00:00
mtrace.c Shorten compile commands run by the build system 2011-09-18 17:34:37 -04:00
mtrace.h ChangeLog, super.c: 2001-01-12 21:05:57 +00:00
pass1.c e2fsck: optimize away repeated calls to gettext() 2019-12-13 23:30:53 -05:00
pass1b.c e2fsck: don't try to rehash a deleted directory 2019-12-20 12:39:00 -05:00
pass2.c e2fsck: optimize away repeated calls to gettext() 2019-12-13 23:30:53 -05:00
pass3.c e2fsck: update the quota records when the root directory is recreated 2019-09-02 20:35:14 -04:00
pass4.c e2fsck: set dir_nlink feature if large dir exists 2018-06-22 18:08:54 -04:00
pass5.c e2fsck: remove an potentially ambiguous dangling else clause 2019-05-12 02:23:08 -04:00
problem.c e2fsck: check the validity of the casefold flag 2019-09-03 10:37:51 -04:00
problem.h e2fsck: check the validity of the casefold flag 2019-09-03 10:37:51 -04:00
problemP.h e2fsck: add support for saving the problem code log 2019-05-06 10:15:41 -04:00
quota.c e2fsck: add proper error checking in move_quota_inode 2018-06-24 13:52:10 -04:00
readahead.c e2fsck: fix hang in readahead code if last block in fs is metadata 2018-06-28 11:10:58 -04:00
recovery.c Fix typos in code comments and developer docs 2017-10-15 23:00:11 -04:00
region.c Fix typos in code comments and developer docs 2017-10-15 23:00:11 -04:00
rehash.c e2fsck: fix use after free in calculate_tree() 2020-01-01 13:41:34 -05:00
revoke.c Fix typos in error messages and documentation 2017-10-15 23:00:03 -04:00
scantest.c e2fsprogs: introduce ext2fs_close_free() helper 2014-07-05 21:06:48 -04:00
sigcatcher.c Eliminate unused variable and unused label warnings from Android build 2015-07-13 10:47:16 -04:00
super.c e2fsck: remove resize inode if both resize_inode and meta_bg are enabled 2018-08-11 19:04:38 -04:00
unix.c e2fsck: fix XML validity problem with the problem log 2019-05-10 18:36:46 -04:00
util.c Fix gcc and clang warnings 2018-06-23 23:00:50 -04:00