[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20111101230642.GK32161@thunk.org>
Date: Tue, 1 Nov 2011 19:06:42 -0400
From: Ted Ts'o <tytso@....edu>
To: Eryu Guan <guaneryu@...il.com>
Cc: linux-ext4@...r.kernel.org, Jan Kara <jack@...e.cz>
Subject: Re: [PATCH 1/2] jbd/jbd2: validate sb->s_first in
journal_get_superblock()
On Tue, Nov 01, 2011 at 10:05:03AM +0800, Eryu Guan wrote:
> I hit a J_ASSERT(blocknr != 0) failure in cleanup_journal_tail() when
> mounting a fsfuzzed ext3 image. It turns out that the corrupted ext3
> image has s_first = 0 in journal superblock, and the 0 is passed to
> journal->j_head in journal_reset(), then to blocknr in
> cleanup_journal_tail(), in the end the J_ASSERT failed.
>
> So validate s_first after reading journal superblock from disk in
> journal_get_superblock() to ensure s_first is valid.
>
> ...
>
> Signed-off-by: Eryu Guan <guaneryu@...il.com>
Thanks, applied. (I took the jbd fixup as well, since it's obvious)
- Ted
--
To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists