Upstream information

CVE-2024-45405 at MITRE

Description

`gix-path` is a crate of the `gitoxide` project (an implementation of `git` written in Rust) dealing paths and their conversions. Prior to version 0.10.11, `gix-path` runs `git` to find the path of a configuration file associated with the `git` installation, but improperly resolves paths containing unusual or non-ASCII characters, in rare cases enabling a local attacker to inject configuration leading to code execution. Version 0.10.11 contains a patch for the issue.

In `gix_path::env`, the underlying implementation of the `installation_config` and `installation_config_prefix` functions calls `git config -l --show-origin` to find the path of a file to treat as belonging to the `git` installation. Affected versions of `gix-path` do not pass `-z`/`--null` to cause `git` to report literal paths. Instead, to cover the occasional case that `git` outputs a quoted path, they attempt to parse the path by stripping the quotation marks. The problem is that, when a path is quoted, it may change in substantial ways beyond the concatenation of quotation marks. If not reversed, these changes can result in another valid path that is not equivalent to the original.

On a single-user system, it is not possible to exploit this, unless `GIT_CONFIG_SYSTEM` and `GIT_CONFIG_GLOBAL` have been set to unusual values or Git has been installed in an unusual way. Such a scenario is not expected. Exploitation is unlikely even on a multi-user system, though it is plausible in some uncommon configurations or use cases. In general, exploitation is more likely to succeed if users are expected to install `git` themselves, and are likely to do so in predictable locations; locations where `git` is installed, whether due to usernames in their paths or otherwise, contain characters that `git` quotes by default in paths, such as non-English letters and accented letters; a custom `system`-scope configuration file is specified with the `GIT_CONFIG_SYSTEM` environment variable, and its path is in an unusual location or has strangely named components; or a `system`-scope configuration file is absent, empty, or suppressed by means other than `GIT_CONFIG_NOSYSTEM`. Currently, `gix-path` can treat a `global`-scope configuration file as belonging to the installation if no higher scope configuration file is available. This increases the likelihood of exploitation even on a system where `git` is installed system-wide in an ordinary way. However, exploitation is expected to be very difficult even under any combination of those factors.

SUSE information

Overall state of this security issue: Pending

This issue is currently rated as having moderate severity.

CVSS v3 Scores
  SUSE
Base Score 5.6
Vector CVSS:3.1/AV:L/AC:H/PR:H/UI:R/S:U/C:H/I:H/A:N
Attack Vector Local
Attack Complexity High
Privileges Required High
User Interaction Required
Scope Unchanged
Confidentiality Impact High
Integrity Impact High
Availability Impact None
CVSSv3 Version 3.1
CVSS v4 Scores
  SUSE
Base Score 5.3
Vector CVSS:4.0/AV:L/AC:H/AT:P/PR:H/UI:A/VC:H/VI:H/VA:N/SC:N/SI:N/SA:N
Attack Vector Local
Attack Complexity High
Attack Requirements Present
Privileges Required High
User Interaction Active
Vulnerable System Confidentiality Impact High
Vulnerable System Integrity Impact High
Vulnerable System Availability Impact None
Subsequent System Confidentiality Impact None
Subsequent System Integrity Impact None
Subsequent System Availability Impact None
CVSSv4 Version 4.0
SUSE Bugzilla entry: 1230682 [NEW]

SUSE Security Advisories:

List of released packages

Product(s) Fixed package version(s) References
openSUSE Leap 15.6
  • cargo-c >= 0.10.3~git0.ee7d7ef-150600.3.3.1
Patchnames:
openSUSE-SLE-15.6-2024-3748
openSUSE Tumbleweed
  • cargo-audit >= 0.20.0~git66.972ac93-3.1
  • cargo-c >= 0.10.3~git0.ee7d7ef-2.1
  • obs-service-cargo >= 1.3.6-5.1
  • onefetch >= 2.22.0-1.1
  • stgit >= 2.4.12-1.1
  • stgit-bash-completion >= 2.4.12-1.1
  • stgit-emacs >= 2.4.12-1.1
  • stgit-fish-completion >= 2.4.12-1.1
  • stgit-vim-plugin >= 2.4.12-1.1
  • stgit-zsh-completion >= 2.4.12-1.1
Patchnames:
openSUSE-Tumbleweed-2024-14353
openSUSE-Tumbleweed-2024-14355
openSUSE-Tumbleweed-2024-14359
openSUSE-Tumbleweed-2024-14363
openSUSE-Tumbleweed-2024-14364


Status of this issue by product and package

Please note that this evaluation state might be work in progress, incomplete or outdated. Also information for service packs in the LTSS phase is only included for issues meeting the LTSS criteria. If in doubt, feel free to contact us for clarification. The updates are grouped by state of their lifecycle. SUSE product lifecycles are documented on the lifecycle page.

Product(s) Source package State
Products under general support and receiving all security fixes.
openSUSE Leap 15.5 cargo-c Affected
openSUSE Leap 15.6 cargo-c Released


SUSE Timeline for this CVE

CVE page created: Fri Sep 6 16:00:06 2024
CVE page last modified: Wed Oct 23 17:59:58 2024