Bug 1734246 (CVE-2019-14284)

Summary: CVE-2019-14284 kernel: denial of service in drivers/block/floppy.c by setup_format_params division-by-zero
Product: [Other] Security Response Reporter: Dhananjay Arunesh <darunesh>
Component: vulnerabilityAssignee: Red Hat Product Security <security-response-team>
Status: CLOSED WONTFIX QA Contact:
Severity: medium Docs Contact:
Priority: medium    
Version: unspecifiedCC: acaringi, airlied, bhu, blc, brdeoliv, bskeggs, dhoward, dvlasenk, esammons, fhrbata, hdegoede, hkrzesin, iboverma, ichavero, itamar, jarodwilson, jeremy, jforbes, jglisse, jlelli, john.j5live, jonathan, josef, jross, jshortt, jstancek, jwboyer, kernel-maint, kernel-mgr, labbott, lgoncalv, linville, matt, mchehab, mcressma, mjg59, mlangsdo, nmurray, plougher, psampaio, rt-maint, rvrbovsk, steved, williams, wmealing, yozone
Target Milestone: ---Keywords: Security
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
A vulnerability was found in the Linux kernel’s floppy disk driver implementation. A local attacker with access to the floppy disk device file (/dev/fd0 through to /dev/fdN) can create a situation that causes the kernel to divide by zero. This requires two consecutive ioctl calls to be issued. The first ioctl call sets the sector and rate values, and the second ioctl is the call to format the floppy disk to the appropriate values. This flaw can cause the system to divide by zero and panic the host. No media (floppy) is required to be inserted for this attack to work properly.
Story Points: ---
Clone Of: Environment:
Last Closed: 2020-01-14 22:31:56 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On: 1734250, 1735597, 1735598, 1735599, 1735600, 1735601, 1735602    
Bug Blocks: 1734249    

Description Dhananjay Arunesh 2019-07-30 04:52:46 UTC
A vulnerability was found in the Linux kernels floppy driver implementation.  A local attacker with access to the floppy disk device file (/dev/fd0 through to /dev/fdN) can create a situation which can convince the kernel to divide by zero.  It requires two consecutive ioctls to be issued the first to set the sector and rate values, the second would be the call to format the floppy disk to the appropriate values.  This can cause the system to divide by zero and panic the host.  No media (floppy) is required to be inserted for this attack to work correctly.


Systems using QEMU will likely have the virtual floppy disk controller (FDC) enabled by default, Linux guests using this configuration will auto-load the floppy kernel module and likely be affected.




External References:
https://cdn.kernel.org/pub/linux/kernel/v5.x/ChangeLog-5.2.3

Upstream commit:
https://github.com/torvalds/linux/commit/f3554aeb991214cbfafd17d55e2bfddb50282e32
https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=f3554aeb991214cbfafd17d55e2bfddb50282e32

Comment 1 Dhananjay Arunesh 2019-07-30 04:56:58 UTC
Created kernel tracking bugs for this issue:

Affects: fedora-all [bug 1734250]

Comment 2 Justin M. Forbes 2019-07-30 14:08:07 UTC
This was fixed for Fedora with the 5.1.20 stable kernel update.

Comment 3 Wade Mealing 2019-08-01 06:09:09 UTC
Mitigation:

The kernel module named 'floppy' contains the affected code, this can be blacklisted using the standard blacklisting techniques or disabled in the systems BIOS.  See https://access.redhat.com/solutions/41278 for how to blacklist a kernel module.

Virtualized guest systems can also remove the system from the guests configuration to ensure that the module does not load.