Bug 1543561 (CVE-2018-6574)

Summary: CVE-2018-6574 golang: arbitrary code execution during "go get" via C compiler options
Product: [Other] Security Response Reporter: Pedro Sampaio <psampaio>
Component: vulnerabilityAssignee: Red Hat Product Security <security-response-team>
Status: CLOSED ERRATA QA Contact:
Severity: medium Docs Contact:
Priority: medium    
Version: unspecifiedCC: admiller, ahardin, amurdaca, apevec, bleanhar, ccoleman, chrisw, dedgar, dmcphers, jcajka, jgoulding, jjoyce, jkeck, jokerman, jschluet, kbasil, lemenkov, lhh, lpeer, markmc, mburns, mchappel, rbryant, renich, sclewis, sisharma, slinaber, ssaha, tdecacqu, vbatts, vbellur
Target Milestone: ---Keywords: Security
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: go 1.8.7, go 1.9.4, go 1.10rc2 Doc Type: If docs needed, set a value
Doc Text:
An arbitrary command execution flaw was found in the way Go's "go get" command handled gcc and clang sensitive options during the build. A remote attacker capable of hosting malicious repositories could potentially use this flaw to cause arbitrary command execution on the client side.
Story Points: ---
Clone Of: Environment:
Last Closed: 2019-06-08 03:39:30 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: 1543562, 1543563, 1545300, 1545319, 1566231    
Bug Blocks: 1498774, 1543565    

Description Pedro Sampaio 2018-02-08 17:54:41 UTC
Go before 1.8.7, Go 1.9.x before 1.9.4, and Go 1.10 pre-releases before Go 1.10rc2 allow "go get" remote command execution during source code build, by leveraging the gcc or clang plugin feature, because -fplugin= and -plugin= arguments were not blocked.

Upstream issue:

https://github.com/golang/go/issues/23672

Upstream patch:

https://go.googlesource.com/go/+/44821583bc16ff2508664fab94360bb856e9e9d6
https://go.googlesource.com/go/+/867fb18b6d5bc73266b68c9a695558a04e060a8a

Comment 1 Pedro Sampaio 2018-02-08 17:55:31 UTC
Created golang tracking bugs for this issue:

Affects: epel-6 [bug 1543563]
Affects: fedora-all [bug 1543562]

Comment 2 Joshua Padman 2018-02-12 09:23:59 UTC
golang was included in Red Hat OpenStack 8 & 9 operational tools only as a technical preview for customers, it was provided without support and is not intended to be deployed in production.

Comment 6 errata-xmlrpc 2018-04-10 08:27:54 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 7

Via RHSA-2018:0878 https://access.redhat.com/errata/RHSA-2018:0878

Comment 10 errata-xmlrpc 2018-05-03 03:48:36 UTC
This issue has been addressed in the following products:

  Red Hat Developer Tools

Via RHSA-2018:1304 https://access.redhat.com/errata/RHSA-2018:1304

Comment 11 Andrej Nemec 2018-05-14 13:56:50 UTC
Statement:

This issue affects the versions of golang as shipped with Red Hat OpenShift Enterprise 3. Red Hat Product Security has rated this issue as having security impact of Moderate. A future update may address this issue. For additional information, refer to the Issue Severity Classification: https://access.redhat.com/security/updates/classification/.