Home    |    View Topics    |    Search    |    Contact Us    |   



Category:   OS (UNIX)  >   FreeBSD Kernel Vendors:   FreeBSD
FreeBSD Kernel Debug Exception Handling Flaw Lets Local Users Gain Elevated Privileges
SecurityTracker Alert ID:  1040866
SecurityTracker URL:
CVE Reference:   CVE-2018-8897   (Links to External Site)
Date:  May 9 2018
Impact:   Denial of service via local system, Disclosure of system information, User access via local system
Fix Available:  Yes  Vendor Confirmed:  Yes  
Version(s): 10.4, 11.1
Description:   A vulnerability was reported in FreeBSD Kernel. A local user can cause denial of service conditions on the target system. A local user can obtain potentially sensitive information from system memory. A local user can obtain elevated privileges on the target system.

The kernel does not properly handle debug exceptions delivered after a stack switch operation via mov SS or pop SS instructions. During the stack switch operation, the exceptions are deferred. As a result, a local user can cause denial of service conditions, obtain potentially sensitive information from system memory, or gain elevated privileges on the target system.

x86 based systems are affected.

Nick Peterson, Everdox Tech LLC, and Andy Lutomirski reported this vulnerability.

Impact:   A local user can cause denial of service conditions on the target system.

A local user can obtain potentially sensitive information from system memory on the target system.

A local user can obtain elevated privileges on the target system.

Solution:   FreeBSD has issued a fix.

The FreeBSD advisory is available at:

Vendor URL: (Links to External Site)
Cause:   State error

Message History:   None.

 Source Message Contents

Subject:  FreeBSD Security Advisory FreeBSD-SA-18:06.debugreg

Hash: SHA512

FreeBSD-SA-18:06.debugreg                                   Security Advisory
                                                          The FreeBSD Project

Topic:          Mishandling of x86 debug exceptions

Category:       core
Module:         kernel
Announced:      2018-05-08
Credits:        Nick Peterson, Everdox Tech LLC
                Andy Lutomirski
Affects:        All supported versions of FreeBSD.
Corrected:      2018-05-08 17:03:33 UTC (stable/11, 11.2-PRERELEASE)
                2018-05-08 17:12:10 UTC (releng/11.1, 11.1-RELEASE-p10)
                2018-05-08 17:05:39 UTC (stable/10, 10.4-STABLE)
                2018-05-08 17:12:10 UTC (releng/10.4, 10.4-RELEASE-p9)
CVE Name:       CVE-2018-8897

For general information regarding FreeBSD Security Advisories,
including descriptions of the fields above, security branches, and the
following sections, please visit <URL:>.

I.   Background

On x86 architecture systems, the stack is represented by the combination of
a stack segment and a stack pointer, which must remain in sync for proper
operation.  Instructions related to manipulating the stack segment have
special handling to facilitate consistency with changes to the stack pointer.

II.  Problem Description

The MOV SS and POP SS instructions inhibit debug exceptions until the
instruction boundary following the next instruction.  If that instruction is
a system call or similar instruction that transfers control to the operating
system, the debug exception will be handled in the kernel context instead of
the user context.

III. Impact

An authenticated local attacker may be able to read sensitive data in kernel
memory, control low-level operating system functions, or may panic the

IV.  Workaround

No workaround is available.

V.   Solution

Upgrade your vulnerable system to a supported FreeBSD stable or
release / security branch (releng) dated after the correction date,
using either a binary or source code patch, and then reboot.

1) To update your vulnerable system via a binary patch:

Systems running a RELEASE version of FreeBSD on the i386 or amd64
platforms can be updated via the freebsd-update(8) utility:

# freebsd-update fetch
# freebsd-update install

And reboot.

2) To update your vulnerable system via a source code patch:

The following patches have been verified to apply to the applicable
FreeBSD release branches.

a) Download the relevant patch from the location below, and verify the
detached PGP signature using your PGP utility.

[FreeBSD 11.1]
# fetch
# fetch
# gpg --verify debugreg.11.1.patch.asc

[FreeBSD 10.4]
# fetch
# fetch
# gpg --verify debugreg.10.4.patch.asc

b) Apply the patch.  Execute the following commands as root:

# cd /usr/src
# patch < /path/to/patch

c) Recompile and install your kernel as described in
<URL:> and reboot the

VI.  Correction details

The following list contains the correction revision numbers for each
affected branch.

Branch/path                                                      Revision
- -------------------------------------------------------------------------
stable/10/                                                        r333370
releng/10.4/                                                      r333371
stable/11/                                                        r333369
releng/11.1/                                                      r333371
- -------------------------------------------------------------------------

To see which files were modified by a particular revision, run the
following command, replacing NNNNNN with the revision number, on a
machine with Subversion installed:

# svn diff -cNNNNNN --summarize svn://

Or visit the following URL, replacing NNNNNN with the revision number:


VII. References


The latest revision of this advisory is available at


Go to the Top of This SecurityTracker Archive Page

Home   |    View Topics   |    Search   |    Contact Us

This web site uses cookies for web analytics. Learn More

Copyright 2021, LLC