From: Chao Yu <chao@kernel.org>
To: Daeho Jeong <daeho43@gmail.com>,
linux-kernel@vger.kernel.org,
linux-f2fs-devel@lists.sourceforge.net, kernel-team@android.com
Cc: chao@kernel.org, Daeho Jeong <daehojeong@google.com>,
Maxim Pleshivenkov <mpleshivenkov@google.com>
Subject: Re: [f2fs-dev] [PATCH] f2fs-tools: fix heap-buffer-overflow of reading SSA from checkpoint area
Date: Wed, 4 Mar 2026 20:24:55 +0800 [thread overview]
Message-ID: <46c69e75-f797-4121-b740-afa1096132cd@kernel.org> (raw)
In-Reply-To: <20260303170036.2242819-1-daeho43@gmail.com>
On 2026/3/4 01:00, Daeho Jeong wrote:
> From: Daeho Jeong <daehojeong@google.com>
>
> Reproduction:
> truncate -s 512M overflow.img
> ./out/host/linux-x86/bin/make_f2fs -g android -b 16384 -w 16384 -O packed_ssa overflow.img
> mkdir -p empty_dir
> export ASAN_OPTIONS=detect_leaks=0:abort_on_error=1
> ./out/host/linux-x86/bin/sload_f2fs -f empty_dir -t /data overflow.img
>
> Result:
> ==306082==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x7df5201e2500 at pc 0x5567ea010583 bp 0x7ffc3386c210 sp 0x7ffc3386b9d8
> READ of size 16384 at 0x7df5201e2500 thread T0
>
> Even though we can reduce the summary block to 4KB, we need to maintain
> backward compatibility for the checkpoint area. Therefore, the summary
> block there must match the block size, so it is correct to use F2FS_BLKSIZE.
>
> Fixes: ad1357c34023 ("f2fs-tools: revert summary entry count from 2048 to 512 in 16kb block support")
> Reported-by: Maxim Pleshivenkov <mpleshivenkov@google.com>
> Signed-off-by: Daeho Jeong <daehojeong@google.com>
Reviewed-by: Chao Yu <chao@kernel.org>
Thanks,
prev parent reply other threads:[~2026-03-04 12:25 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-03-03 17:00 Daeho Jeong
2026-03-04 12:24 ` Chao Yu [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=46c69e75-f797-4121-b740-afa1096132cd@kernel.org \
--to=chao@kernel.org \
--cc=daeho43@gmail.com \
--cc=daehojeong@google.com \
--cc=kernel-team@android.com \
--cc=linux-f2fs-devel@lists.sourceforge.net \
--cc=linux-kernel@vger.kernel.org \
--cc=mpleshivenkov@google.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®