Bug 1267844 (CVE-2015-1335)

Summary: CVE-2015-1335 lxc: Directory traversal flaw when lxc-start is initially setting up the mounts for a container
Product: [Other] Security Response Reporter: Adam Mariš <amaris>
Component: vulnerabilityAssignee: Red Hat Product Security <security-response-team>
Status: CLOSED UPSTREAM QA Contact:
Severity: medium Docs Contact:
Priority: medium    
Version: unspecifiedCC: carnil, karlthered, pokorra.mailinglists, sagarun, thomas.moschny
Target Milestone: ---Keywords: Security
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2019-06-08 02:43:45 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: 1267845, 1267846, 1267847    
Bug Blocks:    

Description Adam Mariš 2015-10-01 08:40:09 UTC
Directory traversal flaw was found in lxc.
As reported in http://seclists.org/oss-sec/2015/q3/648 :

"If an attacker constructs a malicious symlink in the target path of a container mount point, the symlink could be mishandled the next time the container is started and the mount operation may be performed at an undesired target location.

Additionally, if the source path of the mount is a malicious symlink relative to the container, the symlink could be mishandled to bind mount an undesired file or directory into the container.

Direct modification of the host's mount table is not possible since a slave copy of the mount table is used.

An example of an attack that is made possible by this flaw is a user inside of the container could leave behind a malicious symlink, at a mount point target under their control, that would cause /proc/self/attr to be mounted over. lxc-start would then unknowingly write to a "fake" /proc/self/attr/current file, prior to launching the container init, to perform an AppArmor profile transition. The profile transition would not occur and the container init would run under incorrect confinement."

Upstream patch:

https://github.com/lxc/lxc/commit/592fd47a6245508b79fe6ac819fe6d3b2c1289be

Comment 1 Adam Mariš 2015-10-01 08:40:53 UTC
Created lxc tracking bugs for this issue:

Affects: fedora-all [bug 1267845]
Affects: epel-6 [bug 1267846]
Affects: epel-7 [bug 1267847]

Comment 2 Fedora Update System 2015-11-01 02:30:47 UTC
lxc-1.1.4-2.fc23 has been pushed to the Fedora 23 stable repository. If problems still persist, please make note of it in this bug report.

Comment 3 Fedora Update System 2015-11-11 18:22:30 UTC
lxc-1.0.7-4.el7 has been pushed to the Fedora EPEL 7 stable repository. If problems still persist, please make note of it in this bug report.

Comment 4 Fedora Update System 2015-11-11 18:55:03 UTC
lxc-1.0.7-4.el6 has been pushed to the Fedora EPEL 6 stable repository. If problems still persist, please make note of it in this bug report.

Comment 5 Fedora Update System 2015-11-12 00:21:01 UTC
lxc-1.1.4-2.fc22 has been pushed to the Fedora 22 stable repository. If problems still persist, please make note of it in this bug report.

Comment 6 Fedora Update System 2015-11-12 00:48:46 UTC
lxc-1.0.7-4.fc21 has been pushed to the Fedora 21 stable repository. If problems still persist, please make note of it in this bug report.

Comment 7 Product Security DevOps Team 2019-06-08 02:43:45 UTC
This CVE Bugzilla entry is for community support informational purposes only as it does not affect a package in a commercially supported Red Hat product. Refer to the dependent bugs for status of those individual community products.