Bugzilla (bugzilla.redhat.com) will be under maintenance for infrastructure upgrades and will not be unavailable on July 31st between 12:30 AM - 05:30 AM UTC. We appreciate your understanding and patience. You can follow status.redhat.com for details.
Bug 1651863 (CVE-2018-19044) - CVE-2018-19044 keepalived: Improper pathname validation allows for overwrite of arbitrary filenames via symlinks
Summary: CVE-2018-19044 keepalived: Improper pathname validation allows for overwrite ...
Keywords:
Status: CLOSED ERRATA
Alias: CVE-2018-19044
Product: Security Response
Classification: Other
Component: vulnerability
Version: unspecified
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Red Hat Product Security
QA Contact:
URL:
Whiteboard:
Depends On: 1651864 1652397 1654301
Blocks: 1651865
TreeView+ depends on / blocked
 
Reported: 2018-11-21 05:25 UTC by Sam Fowler
Modified: 2021-02-16 22:45 UTC (History)
11 users (show)

Fixed In Version: keepalived 2.0.9
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2019-08-06 19:20:11 UTC


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2019:2285 0 None None None 2019-08-06 12:36:27 UTC

Description Sam Fowler 2018-11-21 05:25:50 UTC
keepalived before version 2.0.9 didn't check for pathnames with symlinks when writing data to a temporary file upon a call to PrintData or PrintStats. This allowed local users to overwrite arbitrary files if fs.protected_symlinks is set to 0, as demonstrated by a symlink from /tmp/keepalived.data or /tmp/keepalived.stats to /etc/passwd.


Upstream Patch:

https://github.com/acassen/keepalived/commit/04f2d32871bb3b11d7dc024039952f2fe2750306


Upstream Issue:

https://github.com/acassen/keepalived/issues/1048


Reference:

https://bugzilla.suse.com/show_bug.cgi?id=1015141

Comment 1 Sam Fowler 2018-11-21 05:26:25 UTC
Created keepalived tracking bugs for this issue:

Affects: fedora-all [bug 1651864]

Comment 6 Adam Mariš 2018-11-29 14:19:54 UTC
Statement:

This issue affects the versions of keepalived as shipped with Red Hat Enterprise Linux 6 and 7.

Red Hat Enterprise Linux 6 is now in Maintenance Support 2 Phase of the support and maintenance life cycle. This has been rated as having a security impact of Moderate, and is not currently planned to be addressed in future updates. For additional information, refer to the Red Hat Enterprise Linux Life Cycle: https://access.redhat.com/support/policy/updates/errata/.

The keepalived packages shipped with Red Hat Enterprise Linux 6 and 7 are not built with dbus support, therefore vulnerable PrintData and PrintStats methods are not compiled in resulting RPM, which means this issue cannot be exploited via dbus messages on Red Hat Enterprise Linux 6 and 7. However, creation of pidfiles is also vulnerable to symlink attack and it is possible for local attacker to overwrite arbitrary file with the process identifiers of keepalived processes, but only if keepalived was launched with option to change pidfile location pointing to unsafe location and attacker is able to exploit Time-of-check Time-of-use race condition and create a symlink during a very small time frame in the same location the pidfile was specified. The default location used for pidfiles is safe. Red Hat Enterprise Linux 7 is by default configured with fs.protected_symlinks=1 which largely mitigates symlink attacks.

Comment 8 errata-xmlrpc 2019-08-06 12:36:27 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 7

Via RHSA-2019:2285 https://access.redhat.com/errata/RHSA-2019:2285

Comment 9 Product Security DevOps Team 2019-08-06 19:20:11 UTC
This bug is now closed. Further updates for individual products will be reflected on the CVE page(s):

https://access.redhat.com/security/cve/cve-2018-19044


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