From: Tejun Heo <tj@kernel.org>
To: syzbot
<bot+ea75c0ffcd353d32515f064aaebefc5279e6161e@syzkaller.appspotmail.com>
Cc: jiangshanlai@gmail.com, linux-kernel@vger.kernel.org,
syzkaller-bugs@googlegroups.com
Subject: Re: KASAN: use-after-free Read in get_work_pool
Date: Thu, 26 Oct 2017 10:58:47 -0700 [thread overview]
Message-ID: <20171026175847.GH59538@devbig577.frc2.facebook.com> (raw)
In-Reply-To: <089e0825d42484310b055c75c3f6@google.com>
Hello,
On Thu, Oct 26, 2017 at 09:35:44AM -0700, syzbot wrote:
> BUG: KASAN: use-after-free in __read_once_size
> include/linux/compiler.h:276 [inline]
> BUG: KASAN: use-after-free in atomic64_read
> arch/x86/include/asm/atomic64_64.h:21 [inline]
> BUG: KASAN: use-after-free in atomic_long_read
> include/asm-generic/atomic-long.h:44 [inline]
> BUG: KASAN: use-after-free in get_work_pool+0x1c2/0x1e0
> kernel/workqueue.c:709
> Read of size 8 at addr ffff8801cc58c378 by task syz-executor5/21326
>
> CPU: 1 PID: 21326 Comm: syz-executor5 Not tainted 4.13.0+ #43
> Hardware name: Google Google Compute Engine/Google Compute Engine,
> BIOS Google 01/01/2011
> Call Trace:
> __dump_stack lib/dump_stack.c:16 [inline]
> dump_stack+0x194/0x257 lib/dump_stack.c:52
> print_address_description+0x73/0x250 mm/kasan/report.c:252
> kasan_report_error mm/kasan/report.c:351 [inline]
> kasan_report+0x24e/0x340 mm/kasan/report.c:409
> __asan_report_load8_noabort+0x14/0x20 mm/kasan/report.c:430
> __read_once_size include/linux/compiler.h:276 [inline]
> atomic64_read arch/x86/include/asm/atomic64_64.h:21 [inline]
> atomic_long_read include/asm-generic/atomic-long.h:44 [inline]
> get_work_pool+0x1c2/0x1e0 kernel/workqueue.c:709
> __queue_work+0x235/0x1150 kernel/workqueue.c:1401
> queue_work_on+0x16a/0x1c0 kernel/workqueue.c:1486
> queue_work include/linux/workqueue.h:489 [inline]
> strp_check_rcv+0x25/0x30 net/strparser/strparser.c:553
> kcm_attach net/kcm/kcmsock.c:1439 [inline]
> kcm_attach_ioctl net/kcm/kcmsock.c:1460 [inline]
> kcm_ioctl+0x826/0x1610 net/kcm/kcmsock.c:1695
> sock_do_ioctl+0x65/0xb0 net/socket.c:961
> sock_ioctl+0x2c2/0x440 net/socket.c:1058
> vfs_ioctl fs/ioctl.c:45 [inline]
> do_vfs_ioctl+0x1b1/0x1530 fs/ioctl.c:685
> SYSC_ioctl fs/ioctl.c:700 [inline]
> SyS_ioctl+0x8f/0xc0 fs/ioctl.c:691
> entry_SYSCALL_64_fastpath+0x1f/0xbe
Looks like kcm is trying to reuse a work item whose last workqueue has
been destroyed without re-initing it. A work item needs to be
reinit'd.
Thanks.
--
tejun
next prev parent reply other threads:[~2017-10-26 17:58 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-10-26 16:35 KASAN: use-after-free Read in get_work_pool syzbot
2017-10-26 16:38 ` Dmitry Vyukov
2017-10-26 17:58 ` Tejun Heo [this message]
2017-10-27 6:00 ` Dmitry Vyukov
2017-10-27 21:18 ` Cong Wang
2017-12-06 12:50 ` Dmitry Vyukov
2018-02-14 13:45 ` Dmitry Vyukov
2018-03-11 21:34 ` Eric Biggers
2018-03-11 22:35 ` Tom Herbert
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=20171026175847.GH59538@devbig577.frc2.facebook.com \
--to=tj@kernel.org \
--cc=bot+ea75c0ffcd353d32515f064aaebefc5279e6161e@syzkaller.appspotmail.com \
--cc=jiangshanlai@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=syzkaller-bugs@googlegroups.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