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

critical Nessus Plugin ID 171871

Synopsis

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

Description

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

- 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)

- libgit2 is a cross-platform, linkable library implementation of Git. When using an SSH remote with the optional libssh2 backend, libgit2 does not perform certificate checking by default. Prior versions of libgit2 require the caller to set the `certificate_check` field of libgit2's `git_remote_callbacks` structure - if a certificate check callback is not set, libgit2 does not perform any certificate checking.
This means that by default - without configuring a certificate check callback, clients will not perform validation on the server SSH keys and may be subject to a man-in-the-middle attack. Users are encouraged to upgrade to v1.4.5 or v1.5.1. Users unable to upgrade should ensure that all relevant certificates are manually checked. (CVE-2023-22742)

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

Solution

Upgrade the libgit2 packages.

For Debian 10 buster, these problems have been fixed in version 0.27.7+dfsg.1-0.2+deb10u1.

See Also

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

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

https://www.debian.org/lts/security/2023/dla-3340

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

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

https://security-tracker.debian.org/tracker/CVE-2023-22742

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

Plugin Details

Severity: Critical

ID: 171871

File Name: debian_DLA-3340.nasl

Version: 1.0

Type: local

Agent: unix

Published: 2/24/2023

Updated: 2/24/2023

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

Risk Information

VPR

Risk Factor: Medium

Score: 5.9

CVSS v2

Risk Factor: High

Base Score: 7.5

Temporal Score: 5.5

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

CVSS Score Source: CVE-2020-12279

CVSS v3

Risk Factor: Critical

Base Score: 9.8

Temporal Score: 8.5

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:U/RL:O/RC:C

Vulnerability Information

CPE: p-cpe:/a:debian:debian_linux:libgit2-27, p-cpe:/a:debian:debian_linux:libgit2-dev, cpe:/o:debian:debian_linux:10.0

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

Exploit Ease: No known exploits are available

Patch Publication Date: 2/23/2023

Vulnerability Publication Date: 4/27/2020

Reference Information

CVE: CVE-2020-12278, CVE-2020-12279, CVE-2023-22742