]> git.ipfire.org Git - thirdparty/git.git/commit
Merge branch 'ml/replace-auto-execok'
authorJohannes Sixt <j6t@kdbg.org>
Tue, 8 Jul 2025 19:19:28 +0000 (21:19 +0200)
committerJohannes Sixt <j6t@kdbg.org>
Tue, 8 Jul 2025 19:20:21 +0000 (21:20 +0200)
commit88125ffe702fcc3aaf5dbcd8b87f74752291f294
treee717dfb47119d485a59445007e708e7c12dc5090
parente8dd723956bee3809931ecc33b80d134a7f39889
parenta1ccd2512072cf52835050f4c97a4fba9f0ec8f9
Merge branch 'ml/replace-auto-execok'

This addresses CVE-2025-46334, Git GUI malicious command injection on
Windows.

A malicious repository can ship versions of sh.exe or typical textconv
filter programs such as astextplain.  Due to the unfortunate design of
Tcl on Windows, the search path when looking for an executable always
includes the current directory.  The mentioned programs are invoked when
the user selects "Git Bash" or "Browse Files" from the menu.

* ml/replace-auto-execok:
  git-gui: override exec and open only on Windows
  git-gui: sanitize $PATH on all platforms
  git-gui: assure PATH has only absolute elements.
  git-gui: cleanup git-bash menu item
  git-gui: avoid auto_execok in do_windows_shortcut
  git-gui: avoid auto_execok for git-bash menu item
  git-gui: remove unused proc is_shellscript
  git-gui: remove special treatment of Windows from open_cmd_pipe
  git-gui: use only the configured shell
  git-gui: make _shellpath usable on startup
  git-gui: use [is_Windows], not bad _shellpath
  git-gui: _which, only add .exe suffix if not present

Signed-off-by: Johannes Sixt <j6t@kdbg.org>
git-gui.sh