Debian dla-3239 : git - security update

high Nessus Plugin ID 168740

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-3239 advisory.

- ------------------------------------------------------------------------- Debian LTS Advisory DLA-3239-2 [email protected] https://www.debian.org/lts/security/ Sylvain Beucler December 14, 2022 https://wiki.debian.org/LTS
- -------------------------------------------------------------------------

Package : git Version : 1:2.20.1-2+deb10u6

In rare conditions, the previous git update released as DLA-3239-1 could generate a segmentation fault, which prevented its availability on armhf architecture. This update addresses this issue. For reference the original advisory text follows.

Multiple issues were found in Git, a distributed revision control system. An attacker may cause other local users into executing arbitrary commands, leak information from the local filesystem, and bypass restricted shell.

Note: Due to new security checks, access to repositories owned and accessed by different local users may now be rejected by Git; in case changing ownership is not practical, git displays a way to bypass these checks using the new 'safe.directory' configuration entry.

CVE-2022-24765

Git is not checking the ownership of directories in a local multi-user system when running commands specified in the local repository configuration. This allows the owner of the repository to cause arbitrary commands to be executed by other users who access the repository.

CVE-2022-29187

An unsuspecting user could still be affected by the issue reported in CVE-2022-24765, for example when navigating as root into a shared tmp directory that is owned by them, but where an attacker could create a git repository.

CVE-2022-39253

Exposure of sensitive information to a malicious actor. When performing a local clone (where the source and target of the clone are on the same volume), Git copies the contents of the source's `$GIT_DIR/objects` directory into the destination by either creating hardlinks to the source contents, or copying them (if hardlinks are disabled via `--no-hardlinks`). A malicious actor could convince a victim to clone a repository with a symbolic link pointing at sensitive information on the victim's machine.

CVE-2022-39260

`git shell` improperly uses an `int` to represent the number of entries in the array, allowing a malicious actor to intentionally overflow the return value, leading to arbitrary heap writes. Because the resulting array is then passed to `execv()`, it is possible to leverage this attack to gain remote code execution on a victim machine.

For Debian 10 buster, this problem has been fixed in version 1:2.20.1-2+deb10u6.

We recommend that you upgrade your git packages.

For the detailed security status of git please refer to its security tracker page at:
https://security-tracker.debian.org/tracker/git

Further information about Debian LTS security advisories, how to apply these updates to your system and frequently asked questions can be found at: https://wiki.debian.org/LTS

Tenable has extracted the preceding description block directly from the Debian security advisory.

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 git packages.

See Also

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

https://security-tracker.debian.org/tracker/CVE-2022-24765

https://security-tracker.debian.org/tracker/CVE-2022-29187

https://security-tracker.debian.org/tracker/CVE-2022-39253

https://security-tracker.debian.org/tracker/CVE-2022-39260

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

Plugin Details

Severity: High

ID: 168740

File Name: debian_DLA-3239.nasl

Version: 1.4

Type: local

Agent: unix

Published: 12/14/2022

Updated: 1/22/2025

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

Risk Information

VPR

Risk Factor: Medium

Score: 6.7

CVSS v2

Risk Factor: Medium

Base Score: 6.9

Temporal Score: 5.1

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

CVSS Score Source: CVE-2022-29187

CVSS v3

Risk Factor: High

Base Score: 8.8

Temporal Score: 7.7

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

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

CVSS Score Source: CVE-2022-39260

Vulnerability Information

CPE: p-cpe:/a:debian:debian_linux:git-all, cpe:/o:debian:debian_linux:10.0, p-cpe:/a:debian:debian_linux:git-cvs, p-cpe:/a:debian:debian_linux:git, p-cpe:/a:debian:debian_linux:git-daemon-sysvinit, p-cpe:/a:debian:debian_linux:git-gui, p-cpe:/a:debian:debian_linux:git-mediawiki, p-cpe:/a:debian:debian_linux:git-email, p-cpe:/a:debian:debian_linux:git-daemon-run, p-cpe:/a:debian:debian_linux:git-doc, p-cpe:/a:debian:debian_linux:git-svn, p-cpe:/a:debian:debian_linux:gitk, p-cpe:/a:debian:debian_linux:git-man, p-cpe:/a:debian:debian_linux:gitweb, p-cpe:/a:debian:debian_linux:git-el

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: 12/14/2022

Vulnerability Publication Date: 4/12/2022

Reference Information

CVE: CVE-2022-24765, CVE-2022-29187, CVE-2022-39253, CVE-2022-39260