···11+Git v2.43.7 Release Notes
22+=========================
33+44+This release includes fixes for CVE-2025-27613, CVE-2025-27614,
55+CVE-2025-46334, CVE-2025-46835, CVE-2025-48384, CVE-2025-48385, and
66+CVE-2025-48386.
77+88+Fixes since v2.43.6
99+-------------------
1010+1111+ * CVE-2025-27613, Gitk:
1212+1313+ When a user clones an untrusted repository and runs Gitk without
1414+ additional command arguments, any writable file can be created and
1515+ truncated. The option "Support per-file encoding" must have been
1616+ enabled. The operation "Show origin of this line" is affected as
1717+ well, regardless of the option being enabled or not.
1818+1919+ * CVE-2025-27614, Gitk:
2020+2121+ A Git repository can be crafted in such a way that a user who has
2222+ cloned the repository can be tricked into running any script
2323+ supplied by the attacker by invoking `gitk filename`, where
2424+ `filename` has a particular structure.
2525+2626+ * CVE-2025-46334, Git GUI (Windows only):
2727+2828+ A malicious repository can ship versions of sh.exe or typical
2929+ textconv filter programs such as astextplain. On Windows, path
3030+ lookup can find such executables in the worktree. These programs
3131+ are invoked when the user selects "Git Bash" or "Browse Files" from
3232+ the menu.
3333+3434+ * CVE-2025-46835, Git GUI:
3535+3636+ When a user clones an untrusted repository and is tricked into
3737+ editing a file located in a maliciously named directory in the
3838+ repository, then Git GUI can create and overwrite any writable
3939+ file.
4040+4141+ * CVE-2025-48384, Git:
4242+4343+ When reading a config value, Git strips any trailing carriage
4444+ return and line feed (CRLF). When writing a config entry, values
4545+ with a trailing CR are not quoted, causing the CR to be lost when
4646+ the config is later read. When initializing a submodule, if the
4747+ submodule path contains a trailing CR, the altered path is read
4848+ resulting in the submodule being checked out to an incorrect
4949+ location. If a symlink exists that points the altered path to the
5050+ submodule hooks directory, and the submodule contains an executable
5151+ post-checkout hook, the script may be unintentionally executed
5252+ after checkout.
5353+5454+ * CVE-2025-48385, Git:
5555+5656+ When cloning a repository Git knows to optionally fetch a bundle
5757+ advertised by the remote server, which allows the server-side to
5858+ offload parts of the clone to a CDN. The Git client does not
5959+ perform sufficient validation of the advertised bundles, which
6060+ allows the remote side to perform protocol injection.
6161+6262+ This protocol injection can cause the client to write the fetched
6363+ bundle to a location controlled by the adversary. The fetched
6464+ content is fully controlled by the server, which can in the worst
6565+ case lead to arbitrary code execution.
6666+6767+ * CVE-2025-48386, Git:
6868+6969+ The wincred credential helper uses a static buffer (`target`) as a
7070+ unique key for storing and comparing against internal storage. This
7171+ credential helper does not properly bounds check the available
7272+ space remaining in the buffer before appending to it with
7373+ `wcsncat()`, leading to potential buffer overflows.
+7
Documentation/RelNotes/2.44.4.adoc
···11+Git v2.44.4 Release Notes
22+=========================
33+44+This release merges up the fixes that appears in v2.43.7 to address
55+the following CVEs: CVE-2025-27613, CVE-2025-27614, CVE-2025-46334,
66+CVE-2025-46835, CVE-2025-48384, CVE-2025-48385, and CVE-2025-48386.
77+See the release notes for v2.43.7 for details.
+7
Documentation/RelNotes/2.45.4.adoc
···11+Git v2.45.4 Release Notes
22+=========================
33+44+This release merges up the fixes that appears in v2.43.7, and v2.44.4
55+to address the following CVEs: CVE-2025-27613, CVE-2025-27614,
66+CVE-2025-46334, CVE-2025-46835, CVE-2025-48384, CVE-2025-48385, and
77+CVE-2025-48386. See the release notes for v2.43.7 for details.
+7
Documentation/RelNotes/2.46.4.adoc
···11+Git v2.46.4 Release Notes
22+=========================
33+44+This release merges up the fixes that appears in v2.43.7, v2.44.4, and
55+v2.45.4 to address the following CVEs: CVE-2025-27613, CVE-2025-27614,
66+CVE-2025-46334, CVE-2025-46835, CVE-2025-48384, CVE-2025-48385, and
77+CVE-2025-48386. See the release notes for v2.43.7 for details.
+8
Documentation/RelNotes/2.47.3.adoc
···11+Git v2.47.3 Release Notes
22+=========================
33+44+This release merges up the fixes that appears in v2.43.7, v2.44.4,
55+v2.45.4, and v2.46.4 to address the following CVEs: CVE-2025-27613,
66+CVE-2025-27614, CVE-2025-46334, CVE-2025-46835, CVE-2025-48384,
77+CVE-2025-48385, and CVE-2025-48386. See the release notes for v2.43.7
88+for details.
+8
Documentation/RelNotes/2.48.2.adoc
···11+Git v2.48.2 Release Notes
22+=========================
33+44+This release merges up the fixes that appears in v2.43.7, v2.44.4,
55+v2.45.4, v2.46.4, and v2.47.3 to address the following CVEs:
66+CVE-2025-27613, CVE-2025-27614, CVE-2025-46334, CVE-2025-46835,
77+CVE-2025-48384, CVE-2025-48385, and CVE-2025-48386. See the release
88+notes for v2.43.7 for details.
+12
Documentation/RelNotes/2.49.1.adoc
···11+Git v2.49.1 Release Notes
22+=========================
33+44+This release merges up the fixes that appear in v2.43.7, v2.44.4,
55+v2.45.4, v2.46.4, v2.47.3, and v2.48.2 to address the following CVEs:
66+CVE-2025-27613, CVE-2025-27614, CVE-2025-46334, CVE-2025-46835,
77+CVE-2025-48384, CVE-2025-48385, and CVE-2025-48386. See the release
88+notes for v2.43.7 for details.
99+1010+It also contains some updates to various CI bits to work around
1111+and/or to adjust to the deprecation of use of Ubuntu 20.04 GitHub
1212+Actions CI, updates to to Fedora base image.
+22
bundle-uri.c
···297297 struct strbuf line = STRBUF_INIT;
298298 int found_get = 0;
299299300300+ /*
301301+ * The protocol we speak with git-remote-https(1) uses a space to
302302+ * separate between URI and file, so the URI itself must not contain a
303303+ * space. If it did, an adversary could change the location where the
304304+ * downloaded file is being written to.
305305+ *
306306+ * Similarly, we use newlines to separate commands from one another.
307307+ * Consequently, neither the URI nor the file must contain a newline or
308308+ * otherwise an adversary could inject arbitrary commands.
309309+ *
310310+ * TODO: Restricting newlines in the target paths may break valid
311311+ * usecases, even if those are a bit more on the esoteric side.
312312+ * If this ever becomes a problem we should probably think about
313313+ * alternatives. One alternative could be to use NUL-delimited
314314+ * requests in git-remote-http(1). Another alternative could be
315315+ * to use URL quoting.
316316+ */
317317+ if (strpbrk(uri, " \n"))
318318+ return error("bundle-uri: URI is malformed: '%s'", file);
319319+ if (strchr(file, '\n'))
320320+ return error("bundle-uri: filename is malformed: '%s'", file);
321321+300322 strvec_pushl(&cp.args, "git-remote-https", uri, NULL);
301323 cp.err = -1;
302324 cp.in = -1;
+1-1
config.c
···29402940 if (value[0] == ' ')
29412941 quote = "\"";
29422942 for (i = 0; value[i]; i++)
29432943- if (value[i] == ';' || value[i] == '#')
29432943+ if (value[i] == ';' || value[i] == '#' || value[i] == '\r')
29442944 quote = "\"";
29452945 if (i && value[i - 1] == ' ')
29462946 quote = "\"";