GHSA-g4v5-fjv9-mhhc: Gitk allows arbitrary command execution

Published Jul 10, 2025
·
Updated

Gitk is a Tcl/Tk based Git history browser. Starting with 2.41.0, a Git repository can be crafted in such a way that with some social engineering a user who has cloned the repository can be tricked into running any script (e.g., Bourne shell, Perl, Python, ...) supplied by the attacker by invoking gitk filename, where filename has a particular structure. The script is run with the privileges of the user. This vulnerability is fixed in 2.43.7, 2.44.4, 2.45.4, 2.46.4, 2.47.3, 2.48.2, 2.49.1, and 2.50.

Affected Software

1 affected component
Git gitk>=2.41.0<2.43.7, >=2.44.0<2.44.4, >=2.45.0<2.45.4, >=2.46.0<2.46.4, >=2.47.0<2.47.3, >=2.48.0<2.48.2, >=2.49.0<2.49.1

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade gitk to a version that resolves this vulnerability.

    Fixed in 2.43.7
  2. Upgrade

    Upgrade gitk to a version that resolves this vulnerability.

    Fixed in 2.44.4
  3. Upgrade

    Upgrade gitk to a version that resolves this vulnerability.

    Fixed in 2.45.4
  4. Upgrade

    Upgrade gitk to a version that resolves this vulnerability.

    Fixed in 2.46.4
  5. Upgrade

    Upgrade gitk to a version that resolves this vulnerability.

    Fixed in 2.47.3
  6. Upgrade

    Upgrade gitk to a version that resolves this vulnerability.

    Fixed in 2.48.2
  7. Upgrade

    Upgrade gitk to a version that resolves this vulnerability.

    Fixed in 2.49.1
  8. Upgrade

    Upgrade gitk to a version that resolves this vulnerability.

    Fixed in 2.50

Event History

Jul 10, 2025
CVE Published
via OSV·03:02 PM
Data Sourced
via OSV·03:02 PM
DescriptionSeverityWeakness

Frequently Asked Questions

1

What conditions are required for exploitation?

The user must have cloned an attacker-crafted repository and then be tricked into invoking gitk with a filename that has the required structure. The attack relies on social engineering rather than occurring merely from cloning the repository.

2

What level of access does successful exploitation provide?

The supplied script runs with the privileges of the user who invokes gitk. An attacker can therefore execute arbitrary scripts, including Bourne shell, Perl, or Python scripts, within that user's permissions.

3

Which versions contain fixes?

Fixes are available in versions 2.43.7, 2.44.4, 2.45.4, 2.46.4, 2.47.3, 2.48.2, 2.49.1, and 2.50. The issue affects Gitk starting with 2.41.0.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203