]> git.ipfire.org Git - people/arne_f/kernel.git/commit
jbd2: don't mark block as modified if the handle is out of credits
authorTheodore Ts'o <tytso@mit.edu>
Sun, 17 Jun 2018 00:21:45 +0000 (20:21 -0400)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 11 Jul 2018 14:26:44 +0000 (16:26 +0200)
commit8ef97ef67ce0f8fc3d32c7218e6b412e479ee2ab
tree7bde43b8a933a6bef6901fa20ae2617520fd0816
parent0f80447d031d91748878e002b9506e323d932467
jbd2: don't mark block as modified if the handle is out of credits

commit e09463f220ca9a1a1ecfda84fcda658f99a1f12a upstream.

Do not set the b_modified flag in block's journal head should not
until after we're sure that jbd2_journal_dirty_metadat() will not
abort with an error due to there not being enough space reserved in
the jbd2 handle.

Otherwise, future attempts to modify the buffer may lead a large
number of spurious errors and warnings.

This addresses CVE-2018-10883.

https://bugzilla.kernel.org/show_bug.cgi?id=200071

Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Cc: stable@kernel.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
fs/jbd2/transaction.c