From: Paolo Bonzini <pbonzini@redhat.com>
To: "Dmitry Vyukov" <dvyukov@google.com>,
"Radim Krčmář" <rkrcmar@redhat.com>,
"Thomas Gleixner" <tglx@linutronix.de>,
"Ingo Molnar" <mingo@redhat.com>,
"H. Peter Anvin" <hpa@zytor.com>,
"x86@kernel.org" <x86@kernel.org>,
"KVM list" <kvm@vger.kernel.org>,
LKML <linux-kernel@vger.kernel.org>,
"Steve Rutherford" <srutherford@google.com>
Cc: syzkaller <syzkaller@googlegroups.com>
Subject: Re: kvm: slab-out-of-bounds write in __apic_accept_irq
Date: Fri, 18 Nov 2016 12:11:30 +0100 [thread overview]
Message-ID: <0d7105a6-cb97-c452-372b-11db1ca6bae4@redhat.com> (raw)
In-Reply-To: <CACT4Y+Za0CLeCSRYScmVtGO0cn5TQ-nCtadO9jRgp0F7H7YFSA@mail.gmail.com>
Dmitry, we are working on some fixes, but at least I have a hard time
following the reports. Please take a break until we push some of the
patches for now-known failures. :)
Thanks,
Paolo
On 18/11/2016 11:22, Dmitry Vyukov wrote:
> Hello,
>
> The following program triggers slab-out-of-bounds write in __apic_accept_irq:
>
> https://gist.githubusercontent.com/dvyukov/6ef34f4a775091d664e18308aa0d5fa6/raw/bf12c7261fbb20cb0ff4318316f0fae7bd948eff/gistfile1.txt
>
> On commit a25f0944ba9b1d8a6813fd6f1a86f1bd59ac25a6 (4.9-rc5)
>
> ==================================================================
> BUG: KASAN: slab-out-of-bounds in __apic_accept_irq+0xb33/0xb50 at
> addr ffff880035d4918f
> Write of size 1 by task a.out/27101
> CPU: 1 PID: 27101 Comm: a.out Not tainted 4.9.0-rc5+ #49
> Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS Bochs 01/01/2011
> ffff880035c16ff0 ffffffff834c2a59 ffffffff00000001 1ffff10006b82d91
> ffffed0006b82d89 0000000041b58ab3 ffffffff895758d0 ffffffff834c276b
> 0000000041b58ab3 0000000000000000 0000000000000002 1ffff10006b82d95
> Call Trace:
> [< inline >] __dump_stack lib/dump_stack.c:15
> [<ffffffff834c2a59>] dump_stack+0x2ee/0x3f5 lib/dump_stack.c:51
> [<ffffffff819f09f1>] kasan_object_err+0x21/0x70 mm/kasan/report.c:159
> [< inline >] print_address_description mm/kasan/report.c:197
> [< inline >] kasan_report_error mm/kasan/report.c:286
> [<ffffffff819f0cdb>] kasan_report+0x1eb/0x4c0 mm/kasan/report.c:306
> [<ffffffff819f106c>] __asan_report_store1_noabort+0x1c/0x20
> mm/kasan/report.c:334
> [<ffffffff8116fb53>] __apic_accept_irq+0xb33/0xb50 arch/x86/kvm/lapic.c:905
> [<ffffffff8117245e>] kvm_apic_set_irq+0x10e/0x180 arch/x86/kvm/lapic.c:495
> [<ffffffff81184ea2>] kvm_irq_delivery_to_apic+0x732/0xc10
> arch/x86/kvm/irq_comm.c:86
> [<ffffffff8118064d>] ioapic_service+0x41d/0x760 arch/x86/kvm/ioapic.c:360
> [<ffffffff811817c5>] ioapic_set_irq+0x275/0x6c0 arch/x86/kvm/ioapic.c:222
> [< inline >] kvm_ioapic_inject_all arch/x86/kvm/ioapic.c:235
> [<ffffffff81183653>] kvm_set_ioapic+0x223/0x310 arch/x86/kvm/ioapic.c:670
> [< inline >] kvm_vm_ioctl_set_irqchip arch/x86/kvm/x86.c:3668
> [<ffffffff810dfe18>] kvm_arch_vm_ioctl+0x1a08/0x23c0 arch/x86/kvm/x86.c:3999
> [<ffffffff81082b4a>] kvm_vm_ioctl+0x1fa/0x1a70
> arch/x86/kvm/../../../virt/kvm/kvm_main.c:3099
> [< inline >] vfs_ioctl fs/ioctl.c:43
> [<ffffffff81abcc44>] do_vfs_ioctl+0x1c4/0x1630 fs/ioctl.c:679
> [< inline >] SYSC_ioctl fs/ioctl.c:694
> [<ffffffff81abe144>] SyS_ioctl+0x94/0xc0 fs/ioctl.c:685
> [<ffffffff88147985>] entry_SYSCALL_64_fastpath+0x23/0xc6
> arch/x86/entry/entry_64.S:209
>
> Object at ffff880035d48bc0, in cache kmalloc-2048 size: 2048
> Allocated:
> PID = 27101
> [ 291.279030] [<ffffffff8127101b>] save_stack_trace+0x1b/0x20
> [ 291.279030] [<ffffffff819efce3>] save_stack+0x43/0xd0
> [ 291.279030] [<ffffffff819effad>] kasan_kmalloc+0xad/0xe0
> [ 291.279030] [<ffffffff819ec32c>] kmem_cache_alloc_trace+0x12c/0x710
> [ 291.279030] [<ffffffff81182ca0>] kvm_ioapic_init+0xa0/0x680
> [ 291.279030] [<ffffffff810df5e7>] kvm_arch_vm_ioctl+0x11d7/0x23c0
> [ 291.279030] [<ffffffff81082b4a>] kvm_vm_ioctl+0x1fa/0x1a70
> [ 291.279030] [<ffffffff81abcc44>] do_vfs_ioctl+0x1c4/0x1630
> [ 291.279030] [<ffffffff81abe144>] SyS_ioctl+0x94/0xc0
> [ 291.279030] [<ffffffff88147985>] entry_SYSCALL_64_fastpath+0x23/0xc6
>
> Memory state around the buggy address:
> ffff880035d49080: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
> ffff880035d49100: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
>> ffff880035d49180: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
> ^
> ffff880035d49200: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
> ffff880035d49280: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
> ==================================================================
> Disabling lock debugging due to kernel taint
> Disabled LAPIC found during irq injection
>
prev parent reply other threads:[~2016-11-18 11:11 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-11-18 10:22 Dmitry Vyukov
2016-11-18 11:11 ` Paolo Bonzini [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=0d7105a6-cb97-c452-372b-11db1ca6bae4@redhat.com \
--to=pbonzini@redhat.com \
--cc=dvyukov@google.com \
--cc=hpa@zytor.com \
--cc=kvm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@redhat.com \
--cc=rkrcmar@redhat.com \
--cc=srutherford@google.com \
--cc=syzkaller@googlegroups.com \
--cc=tglx@linutronix.de \
--cc=x86@kernel.org \
/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®