CVE-2019-14271: Github.com/docker/docker Moby Docker Cp Broken With Vulnerability

CRITICAL
Advisory Identifier: GHSA-v2cv-wwxq-qq97
CVSS 9.8
CWE-94 CWE-665
Published
Advisory Summary

CVE-2019-14271 is a CRITICAL (CVSS 9.8) moby docker cp broken with vulnerability (CWE-94: Improper Control of Generation of Code ('Code Injection')) affecting Github.com/docker/docker libraries in the Go ecosystem. The issue involves moby docker cp broken with debian containers. Remediation is available by upgrading affected packages to version 19.03.1.

CVE-2019-14271 at a Glance

CVE Identifier CVE-2019-14271
GHSA Identifier GHSA-v2cv-wwxq-qq97
Severity CRITICAL
CVSS v3.1 Base Score 9.8
CWE Classification CWE-94: Improper Control of Generation of Code ('Code Injection')
Affected Product Github.com/docker/docker
Package Ecosystem Go
Published Date
Last Updated

Security Impact

CVSS: 9.8

The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H).

Attack Vector Network (AV:N)
Attack Complexity Low (AC:L)
Privileges Required None (PR:N)
User Interaction None (UI:N)
Scope Unchanged (S:U)
Confidentiality High (C:H)
Integrity High (I:H)
Availability High (A:H)

How to Fix CVE-2019-14271

To remediate this vulnerability, upgrade all affected Github.com/docker/docker dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

github.com/docker/docker fixed: 19.03.1
Upgrade github.com/docker/docker to 19.03.1
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

inspect dependencies for github.com/docker/docker

How to Check if You Are Affected

To determine whether your application is affected by CVE-2019-14271, inspect your project dependencies for Github.com/docker/docker:

inspect dependencies for github.com/docker/docker

Analyze the terminal output to locate any version of Github.com/docker/docker in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 19.03.1), your application is affected.

Note: Verify declared build manifests and deployed runtime container environments.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-94: Improper Control of Generation of Code ('Code Injection'), where the product constructs all or part of a code segment using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify the syntax or behavior of the intended code segment. In Github.com/docker/docker, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

In Docker 19.03.x before 19.03.1 linked against the GNU C Library (aka glibc), code injection can occur when the nsswitch facility dynamically loads a library inside a chroot that contains the contents of the container.

CVE-2019-14271 Affected Github.com/docker/docker Versions

1 component(s)
Fixed Versions:
19.03.1
Product / Package Ecosystem Affected Versions Fixed Version
github.com/docker/docker
Go
≥ 19.03.0
< 19.03.1
19.03.1

References

Frequently Asked Questions

What is CVE-2019-14271?
CVE-2019-14271 is a security vulnerability in Github.com/docker/docker involving Moby Docker cp broken with debian containers under CWE-94: Improper Control of Generation of Code ('Code Injection').
Which Github.com/docker/docker versions are affected?
Affected versions include releases prior to 19.03.1 across affected packages: github.com/docker/docker.
What version fixes CVE-2019-14271?
Upgrading to 19.03.1 (or the latest patched release for your respective branch) resolves the vulnerability.
Is github.com/docker/docker affected?
Yes, github.com/docker/docker is affected in releases prior to 19.03.1. Upgrade your dependency to 19.03.1 or later.
What is the CVSS score of CVE-2019-14271?
CVE-2019-14271 has a CVSS v3.1 base score of 9.8 (CRITICAL) with vector string CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H.
What CWE is associated with CVE-2019-14271?
CVE-2019-14271 is classified under CWE-94: Improper Control of Generation of Code ('Code Injection') (The product constructs all or part of a code segment using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify the syntax or behavior of the intended code segment.).
How can I check Go dependencies for CVE-2019-14271?
Run the dependency tree command: 'inspect dependencies for github.com/docker/docker'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-v2cv-wwxq-qq97",
  "modified" : "2024-07-08T19:56:40Z",
  "published" : "2022-05-24T16:51:39Z",
  "aliases" : [ "CVE-2019-14271" ],
  "summary" : "Moby Docker cp broken with debian containers",
  "details" : "In Docker 19.03.x before 19.03.1 linked against the GNU C Library (aka glibc), code injection can occur when the nsswitch facility dynamically loads a library inside a chroot that contains the contents of the container.",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H"
  }, {
    "type" : "CVSS_V4",
    "score" : "CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "Go",
      "name" : "github.com/docker/docker"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "19.03.0"
      }, {
        "fixed" : "19.03.1"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2019-14271"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/moby/moby/issues/39449"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/moby/moby/pull/39612"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/moby/moby/commit/11e48badcb67554b3d795241855028f28d244545"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/moby/moby/commit/fa8dd90ceb7bcb9d554d27e0b9087ab83e54bd2b"
  }, {
    "type" : "WEB",
    "url" : "https://docs.docker.com/engine/release-notes"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/moby/moby"
  }, {
    "type" : "WEB",
    "url" : "https://seclists.org/bugtraq/2019/Sep/21"
  }, {
    "type" : "WEB",
    "url" : "https://security.netapp.com/advisory/ntap-20190828-0003"
  }, {
    "type" : "WEB",
    "url" : "https://www.debian.org/security/2019/dsa-4521"
  }, {
    "type" : "WEB",
    "url" : "http://lists.opensuse.org/opensuse-security-announce/2019-08/msg00084.html"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-665", "CWE-94" ],
    "severity" : "CRITICAL",
    "github_reviewed" : true,
    "github_reviewed_at" : "2024-02-01T21:22:37Z",
    "nvd_published_at" : "2019-07-29T18:15:00Z"
  }
}