Bug 1450407 (CVE-2017-8386) - CVE-2017-8386 git: Escape out of git-shell
Summary: CVE-2017-8386 git: Escape out of git-shell
Status: CLOSED ERRATA
Alias: CVE-2017-8386
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: impact=moderate,public=20170505,repor...
Keywords: Reopened, Security
Depends On: 1450409 1450410 1450799 1451691 1480504 1480505
Blocks: 1415638 1450411
TreeView+ depends on / blocked
 
Reported: 2017-05-12 12:43 UTC by Andrej Nemec
Modified: 2019-06-11 11:13 UTC (History)
15 users (show)

(edit)
A flaw was found in the way git-shell handled command-line options for the restricted set of git-shell commands. A remote, authenticated attacker could use this flaw to bypass git-shell restrictions, to view and manipulate files, by abusing the instance of the less command launched using crafted command-line options.
Clone Of:
(edit)
Last Closed: 2019-06-08 03:12:28 UTC


Attachments (Terms of Use)


External Trackers
Tracker ID Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2017:2004 normal SHIPPED_LIVE Moderate: git security and bug fix update 2017-08-01 18:33:36 UTC
Red Hat Product Errata RHSA-2017:2491 normal SHIPPED_LIVE Important: rh-git29-git security update 2017-08-18 01:56:10 UTC

Description Andrej Nemec 2017-05-12 12:43:44 UTC
A vulnerability was found in git concerning the git shell. A user who comes over SSH could run an interactive pager by causing it to spawn "git upload-pack --help".

"git-shell" is a restricted login shell that can be used on a server to prevent SSH clients from running any programs except those needed for git fetches and pushes. If you are not running a server, or if your server has not been explicitly configured to use git-shell as a login shell, you are not affected.

Upstream patch:

https://kernel.googlesource.com/pub/scm/git/git/+/3ec804490a265f4c418a321428c12f3f18b7eff5

References:

https://insinuator.net/2017/05/git-shell-bypass-by-abusing-less-cve-2017-8386/
http://public-inbox.org/git/xmqq8tm5ziat.fsf@gitster.mtv.corp.google.com/

Comment 1 Andrej Nemec 2017-05-12 12:44:36 UTC
Created git tracking bugs for this issue:

Affects: fedora-all [bug 1450409]
Affects: openshift-1 [bug 1450410]

Comment 5 errata-xmlrpc 2017-08-01 20:52:52 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 7

Via RHSA-2017:2004 https://access.redhat.com/errata/RHSA-2017:2004

Comment 7 errata-xmlrpc 2017-08-17 21:56:48 UTC
This issue has been addressed in the following products:

  Red Hat Software Collections for Red Hat Enterprise Linux 6
  Red Hat Software Collections for Red Hat Enterprise Linux 7

Via RHSA-2017:2491 https://access.redhat.com/errata/RHSA-2017:2491


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