Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
SUSE:SLE-12-SP2:GA
qemu-linux-user.11147
0285-char-serial-check-divider-value-aga.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File 0285-char-serial-check-divider-value-aga.patch of Package qemu-linux-user.11147
From a36fe466560fed8d39f20af03635934dc342588b Mon Sep 17 00:00:00 2001 From: Prasad J Pandit <pjp@fedoraproject.org> Date: Wed, 12 Oct 2016 11:28:08 +0530 Subject: [PATCH] char: serial: check divider value against baud base 16550A UART device uses an oscillator to generate frequencies (baud base), which decide communication speed. This speed could be changed by dividing it by a divider. If the divider is greater than the baud base, speed is set to zero, leading to a divide by zero error. Add check to avoid it. Reported-by: Huawei PSIRT <psirt@huawei.com> Signed-off-by: Prasad J Pandit <pjp@fedoraproject.org> Message-Id: <1476251888-20238-1-git-send-email-ppandit@redhat.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> (cherry picked from commit 3592fe0c919cf27a81d8e9f9b4f269553418bb01) [BR: CVE-2016-8669 BSC#1004707] Signed-off-by: Bruce Rogers <brogers@suse.com> --- hw/char/serial.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/hw/char/serial.c b/hw/char/serial.c index f4d167f916..3b531796d8 100644 --- a/hw/char/serial.c +++ b/hw/char/serial.c @@ -150,8 +150,9 @@ static void serial_update_parameters(SerialState *s) int speed, parity, data_bits, stop_bits, frame_size; QEMUSerialSetParams ssp; - if (s->divider == 0) + if (s->divider == 0 || s->divider > s->baudbase) { return; + } /* Start bit. */ frame_size = 1;
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor