Debian DLA-2936-1 : libgit2 - LTS security update

critical Nessus Plugin ID 159090

Synopsis

The remote Debian host is missing one or more security-related updates.

Description

The remote Debian 9 host has packages installed that are affected by multiple vulnerabilities as referenced in the dla-2936 advisory.

- A flaw was found in libgit2 before version 0.27.3. It has been discovered that an unexpected sign extension in git_delta_apply function in delta.c file may lead to an integer overflow which in turn leads to an out of bound read, allowing to read before the base object. An attacker may use this flaw to leak memory addresses or cause a Denial of Service. (CVE-2018-10887)

- A flaw was found in libgit2 before version 0.27.3. A missing check in git_delta_apply function in delta.c file, may lead to an out-of-bound read while reading a binary delta file. An attacker may use this flaw to cause a Denial of Service. (CVE-2018-10888)

- In ng_pkt in transports/smart_pkt.c in libgit2 before 0.26.6 and 0.27.x before 0.27.4, a remote attacker can send a crafted smart-protocol ng packet that lacks a '\0' byte to trigger an out-of-bounds read that leads to DoS. (CVE-2018-15501)

- Integer overflow in the index.c:read_entry() function while decompressing a compressed prefix length in libgit2 before v0.26.2 allows an attacker to cause a denial of service (out-of-bounds read) via a crafted repository index file. (CVE-2018-8098)

- Incorrect returning of an error code in the index.c:read_entry() function leads to a double free in libgit2 before v0.26.2, which allows an attacker to cause a denial of service via a crafted repository index file. (CVE-2018-8099)

- A remote code execution vulnerability exists when Git for Visual Studio improperly sanitizes input, aka 'Git for Visual Studio Remote Code Execution Vulnerability'. This CVE ID is unique from CVE-2019-1349, CVE-2019-1350, CVE-2019-1354, CVE-2019-1387. (CVE-2019-1352)

- An issue was found in Git before v2.24.1, v2.23.1, v2.22.2, v2.21.1, v2.20.2, v2.19.3, v2.18.2, v2.17.3, v2.16.6, v2.15.4, and v2.14.6. When running Git in the Windows Subsystem for Linux (also known as WSL) while accessing a working directory on a regular Windows drive, none of the NTFS protections were active.
(CVE-2019-1353)

- An issue was discovered in libgit2 before 0.28.4 and 0.9x before 0.99.0. path.c mishandles equivalent filenames that exist because of NTFS Alternate Data Streams. This may allow remote code execution when cloning a repository. This issue is similar to CVE-2019-1352. (CVE-2020-12278)

- An issue was discovered in libgit2 before 0.28.4 and 0.9x before 0.99.0. checkout.c mishandles equivalent filenames that exist because of NTFS short names. This may allow remote code execution when cloning a repository. This issue is similar to CVE-2019-1353. (CVE-2020-12279)

Note that Nessus has not tested for this issue but has instead relied only on the application's self-reported version number.

Solution

Upgrade the libgit2 packages.

For Debian 9 stretch, these problems have been fixed in version 0.25.1+really0.24.6-1+deb9u1.

See Also

https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=892961

https://security-tracker.debian.org/tracker/source-package/libgit2

https://www.debian.org/lts/security/2022/dla-2936

https://security-tracker.debian.org/tracker/CVE-2018-10887

https://security-tracker.debian.org/tracker/CVE-2018-10888

https://security-tracker.debian.org/tracker/CVE-2018-15501

https://security-tracker.debian.org/tracker/CVE-2018-8098

https://security-tracker.debian.org/tracker/CVE-2018-8099

https://security-tracker.debian.org/tracker/CVE-2019-1352

https://security-tracker.debian.org/tracker/CVE-2019-1353

https://security-tracker.debian.org/tracker/CVE-2020-12278

https://security-tracker.debian.org/tracker/CVE-2020-12279

https://packages.debian.org/source/stretch/libgit2

Plugin Details

Severity: Critical

ID: 159090

File Name: debian_DLA-2936.nasl

Version: 1.4

Type: local

Agent: unix

Published: 3/21/2022

Updated: 11/3/2023

Supported Sensors: Agentless Assessment, Continuous Assessment, Frictionless Assessment Agent, Nessus Agent, Nessus

Risk Information

VPR

Risk Factor: Medium

Score: 6.7

CVSS v2

Risk Factor: High

Base Score: 9.3

Temporal Score: 7.3

Vector: CVSS2#AV:N/AC:M/Au:N/C:C/I:C/A:C

CVSS Score Source: CVE-2019-1352

CVSS v3

Risk Factor: Critical

Base Score: 9.8

Temporal Score: 8.8

Vector: CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H

Temporal Vector: CVSS:3.0/E:P/RL:O/RC:C

CVSS Score Source: CVE-2020-12279

Vulnerability Information

CPE: p-cpe:/a:debian:debian_linux:libgit2-dev, cpe:/o:debian:debian_linux:9.0, p-cpe:/a:debian:debian_linux:libgit2-24

Required KB Items: Host/local_checks_enabled, Host/Debian/release, Host/Debian/dpkg-l

Exploit Available: true

Exploit Ease: Exploits are available

Patch Publication Date: 3/21/2022

Vulnerability Publication Date: 3/12/2018

Reference Information

CVE: CVE-2018-10887, CVE-2018-10888, CVE-2018-15501, CVE-2018-8098, CVE-2018-8099, CVE-2019-1352, CVE-2019-1353, CVE-2020-12278, CVE-2020-12279

IAVA: 2019-A-0454-S