[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH 0/2] use unsigned type for MegasasState fields
From: |
P J P |
Subject: |
Re: [PATCH 0/2] use unsigned type for MegasasState fields |
Date: |
Wed, 13 May 2020 19:19:42 +0530 (IST) |
Hello Alex,
+-- On Tue, 12 May 2020, Alexander Bulekov wrote --+
| I noticed this since I found a similar issue recently, using a fuzzer. I
| applied your patches, but I can still reproduce the heap-overflow, unless
| I'm missing something:
Strange, because with uint16_t type, 'reply_queue_head' should not turn
negative.
| cat << EOF | qemu-system-i386 -qtest stdio -nographic -monitor none \
| -serial none -M q35 -device megasas -device scsi-cd,drive=null0 \
| -blockdev driver=null-co,read-zeroes=on,node-name=null0 -nographic
| outl 0xcf8 0x80001814
| outl 0xcfc 0xc021
| outl 0xcf8 0x80001818
| outl 0xcf8 0x80001804
| outw 0xcfc 0x7
| outl 0xcf8 0x80001810
| outl 0xcfc 0xe10c0000
| outl 0xcf8 0x8000f810
| write 0x0 0x18 0x060017e1ff00f8ffffffff60efffffffffffffffffffffff
| write 0xff00 0x1 0x06
| write 0xc021e10c0040 0x81
0x755e08ff0000845e08ff0000935e08ff0000a25e08ff0000b15e08ff0000c05e08ff0000cf5e08ff0000de5e08ff0000ed5e08ff0000fc5e08ff00000b5e08ff00001a5e08ff0000295e08ff0000385e08ff0000475e08ff0000565e08ff0000655e08ff0000745e08ff0000835e08ff0000925e08ff0000a15e08ff0000b05e08
| -M pc-q35-5.0 -no-shutdown -M q35 -device megasas -device scsi-cd,drive=null0
-blockdev driver=null-co,read-zeroes=on,node-name=null0 -nographic
| EOF
Are qemu options just above EOF right?
This leads to an assert failure below
qemu/qtest.c:546:qtest_process_command: assertion failed: (words[1] &&
words[2] && words[3])
...
Aborted (core dumped) /tmp/im/bin/qemu-system-x86_64 -qtest
stdio -nographic -monitor none -serial none -M q35 -device megasas -device
scsi-cd,drive=null0 -blockdev driver=null-co,read-zeroes=on,node-name=null0
-nographic < ins
Thank you.
--
Prasad J Pandit / Red Hat Product Security Team
8685 545E B54C 486B C6EB 271E E285 8B5A F050 DE8D
- Re: [PATCH 1/2] megasas: use unsigned type for reply_queue_head, (continued)
- Re: [PATCH 0/2] use unsigned type for MegasasState fields, P J P, 2020/05/12
- Re: [PATCH 0/2] use unsigned type for MegasasState fields, Philippe Mathieu-Daudé, 2020/05/12
- Re: [PATCH 0/2] use unsigned type for MegasasState fields, P J P, 2020/05/12
- Re: [PATCH 0/2] use unsigned type for MegasasState fields, P J P, 2020/05/13
- Re: [PATCH 0/2] use unsigned type for MegasasState fields,
P J P <=
- Re: [PATCH 0/2] use unsigned type for MegasasState fields, Alexander Bulekov, 2020/05/13
- Re: [PATCH 0/2] use unsigned type for MegasasState fields, P J P, 2020/05/13
- Re: [PATCH 0/2] use unsigned type for MegasasState fields, Ding, Ren, 2020/05/13
- Re: [PATCH 0/2] use unsigned type for MegasasState fields, P J P, 2020/05/13
- Re: [PATCH 0/2] use unsigned type for MegasasState fields, Alexander Bulekov, 2020/05/13
- 回复: [PATCH 0/2] use unsigned type for MegasasState fields, Ding, Ren, 2020/05/12
- Re: 回复: [PATCH 0/2] use unsigned type for MegasasState fields, Philippe Mathieu-Daudé, 2020/05/12
- Re: 回复: [PATCH 0/2] use unsigned type for MegasasState fields, P J P, 2020/05/13