Bug 1094265 (CVE-2014-0181)

Summary: CVE-2014-0181 kernel: net: insufficient permision checks of netlink messages
Product: [Other] Security Response Reporter: Petr Matousek <pmatouse>
Component: vulnerabilityAssignee: Red Hat Product Security <security-response-team>
Status: CLOSED ERRATA QA Contact:
Severity: medium Docs Contact:
Priority: medium    
Version: unspecifiedCC: agordeev, aquini, bhu, chazlett, davej, dhoward, edbrand, esammons, fhrbata, gansalmon, iboverma, itamar, jbenc, jforbes, jkacur, jkurik, jonathan, jross, jwboyer, kernel-maint, kernel-mgr, lgoncalv, lwang, madhu.chinakonda, matt, mchehab, mcressma, moshiro, nobody, npajkovs, pholasek, plougher, rt-maint, rvrbovsk, security-response-team, williams, yoguma
Target Milestone: ---Keywords: Security
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
It was found that the permission checks performed by the Linux kernel when a netlink message was received were not sufficient. A local, unprivileged user could potentially bypass these restrictions by passing a netlink socket as stdout or stderr to a more privileged process and altering the output of this process.
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-12-04 17:37:49 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: 1094266, 1094267, 1094268, 1094269, 1094270, 1094271, 1094272, 1097660, 1097661    
Bug Blocks: 1094273    

Description Petr Matousek 2014-05-05 11:40:36 UTC
It is possible to reconfigure the network on Linux by calling write(2)
on an appropriately connected network socket. An unprivileged local
user could use this flaw to reconfigure the network by passing such a
socket as stdout or stderr to a setuid program.

References:
http://seclists.org/oss-sec/2014/q2/162

Upstream commit:
https://git.kernel.org/cgit/linux/kernel/git/davem/net.git/commit/?id=90f62cf30a78721641e08737bda787552428061e
(depends on some of the preceding commits; whole set on http://www.spinics.net/lists/netdev/msg280198.html)

Acknowledgements:

Red Hat would like to thank Andy Lutomirski for reporting this issue.

Comment 3 Petr Matousek 2014-05-05 11:43:20 UTC
Created kernel tracking bugs for this issue:

Affects: fedora-all [bug 1094270]

Comment 5 Petr Matousek 2014-05-08 18:52:28 UTC
Discussion about regression caused by the patch for CVE-2014-0181 --

  http://www.spinics.net/lists/netdev/msg281707.html

Comment 6 John Kacur 2014-05-09 12:41:31 UTC
Upstream versions of the patches (Linus' tree)

Patch 1: 5187cd055b6e81fc6526109456f8b20623148d5f
Patch 2: a53b72c83a4216f2eb883ed45a0cbce014b8e62d
Patch 3: a3b299da869d6e78cf42ae0b1b41797bcb8c5e4b
Patch 4: aa4cf9452f469f16cea8c96283b641b4576d4a7b
Patch 5: 90f62cf30a78721641e08737bda787552428061e

Comment 7 Fedora Update System 2014-05-10 03:20:43 UTC
kernel-3.14.3-200.fc20 has been pushed to the Fedora 20 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 8 Ed Brand 2014-05-13 13:12:21 UTC
Are the RHEL-5/RHEL-6 kernels impacted by this issue?

Comment 9 Petr Matousek 2014-05-14 09:23:02 UTC
Statement:

(none)

Comment 13 Fedora Update System 2014-05-21 23:22:33 UTC
kernel-3.14.4-100.fc19 has been pushed to the Fedora 19 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 14 Jiri Benc 2014-05-27 07:49:58 UTC
The regression mentioned in comment 5 is still discussed upstream. There has been an RFC patch sent which seems to be in the right direction but still needs more work.

Comment 15 Petr Matousek 2014-06-02 06:36:24 UTC
(In reply to Jiri Benc from comment #14)
> The regression mentioned in comment 5 is still discussed upstream. There has
> been an RFC patch sent which seems to be in the right direction but still
> needs more work.

http://www.spinics.net/lists/netdev/msg284505.html

Comment 16 Jiri Benc 2014-06-03 08:49:08 UTC
Upstream commit

2d7a85f4b06e netlink: Only check file credentials for implicit destinations

Comment 17 errata-xmlrpc 2014-07-22 18:00:51 UTC
This issue has been addressed in following products:

  MRG for RHEL-6 v.2

Via RHSA-2014:0913 https://rhn.redhat.com/errata/RHSA-2014-0913.html

Comment 18 Martin Prpič 2014-08-05 12:07:58 UTC
IssueDescription:

It was found that the permission checks performed by the Linux kernel when a netlink message was received were not sufficient. A local, unprivileged user could potentially bypass these restrictions by passing a netlink socket as stdout or stderr to a more privileged process and altering the output of this process.

Comment 19 errata-xmlrpc 2014-08-06 17:11:20 UTC
This issue has been addressed in following products:

  Red Hat Enterprise Linux 7

Via RHSA-2014:1023 https://rhn.redhat.com/errata/RHSA-2014-1023.html

Comment 20 errata-xmlrpc 2014-10-14 06:07:32 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 6

Via RHSA-2014:1392 https://rhn.redhat.com/errata/RHSA-2014-1392.html

Comment 22 errata-xmlrpc 2014-12-04 17:12:30 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 5

Via RHSA-2014:1959 https://rhn.redhat.com/errata/RHSA-2014-1959.html