Note: This is a public test instance of Red Hat Bugzilla. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback at bugzilla.redhat.com.
Bug 1594054 (CVE-2018-12617) - CVE-2018-12617 Qemu: qemu-guest-agent: Integer overflow causes segmentation fault in qmp_guest_file_read()
Summary: CVE-2018-12617 Qemu: qemu-guest-agent: Integer overflow causes segmentation f...
Keywords:
Status: CLOSED ERRATA
Alias: CVE-2018-12617
Product: Security Response
Classification: Other
Component: vulnerability
Version: unspecified
Hardware: All
OS: Linux
low
low
Target Milestone: ---
Assignee: Red Hat Product Security
QA Contact:
URL:
Whiteboard:
Depends On: 1594055 1594056 1639975 1644530 1645015 1645016 1645018
Blocks:
TreeView+ depends on / blocked
 
Reported: 2018-06-22 00:47 UTC by Sam Fowler
Modified: 2021-10-25 09:45 UTC (History)
34 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2021-10-25 09:45:46 UTC
Embargoed:


Attachments (Terms of Use)

Description Sam Fowler 2018-06-22 00:47:19 UTC
The QEMU Guest Agent in QEMU is vulnerable to an integer overflow in the 
qmp_guest_file_read(). An attacker could exploit this by sending a crafted QMP 
command (including guest-file-read with a large count value) to the agent via 
the listening socket to trigger a g_malloc() call with a large memory chunk 
resulting in a segmentation fault.

A user could use this flaw to crash the QEMU guest agent process resulting in DoS.

Upstream Patch:
---------------
  -> https://git.qemu.org/?p=qemu.git;a=commit;h=141b197408ab398c4f474ac1a728ab316e921f2b

References:
-----------
  -> https://www.openwall.com/lists/oss-security/2018/10/17/4
  -> https://gist.github.com/fakhrizulkifli/c7740d28efa07dafee66d4da5d857ef6

Comment 1 Sam Fowler 2018-06-22 00:48:20 UTC
Created qemu tracking bugs for this issue:

Affects: fedora-all [bug 1594055]

Comment 3 Joshua Padman 2018-07-25 11:45:45 UTC
The builds of qemu-kvm-rhev used by OpenStack do not have building of the guest agent enabled. Therefore the vulnerable code is not built and shipper to customers.

Comment 5 Prasad Pandit 2018-10-17 04:15:39 UTC
Acknowledgments:

Name: Fakhri Zulkifli

Comment 15 Philippe Mathieu-Daudé 2020-04-16 06:34:31 UTC
This issue is fixed by upstream commits 5d3586b834..1329651fb4:

- 1329651fb4 qga: Restrict guest-file-read count to 48 MB to avoid crashes
- ead83a136d qga: Extract qmp_guest_file_read() to common commands.c
- 5d3586b834 qga: Extract guest_file_handle_find() to commands-common.h

Comment 16 Philippe Mathieu-Daudé 2020-04-16 06:35:30 UTC
This issue is fixed by upstream commits 5d3586b834..1329651fb4:

- 5d3586b834 qga: Extract guest_file_handle_find() to commands-common.h
- ead83a136d qga: Extract qmp_guest_file_read() to common commands.c
- 1329651fb4 qga: Restrict guest-file-read count to 48 MB to avoid crashes


Note You need to log in before you can comment on or make changes to this bug.