Files
git/Documentation
brian m. carlson dbbd2e7ee3 hex: allow only lowercase object IDs in breaking changes mode
Git has historically allowed either lowercase or uppercase hex for
object IDs, but it has always emitted only lowercase.  This has caused
people to expect only lowercase and not handle uppercase.

As an example, Git's own example hooks look for "[0-9a-f]" in several
places, but there are many other Git-adjacent pieces of software,
including Gitolite, which make the assumption that object IDs are always
lowercase.  This is not to criticize the authors of these projects, but
rather to point out how common this assumption is.  In fact, it's so
common that we had only one test in our codebase that failed when we
reject uppercase object IDs.

More critically, it leads people to make security-based assumptions that
an object ID either does not contain uppercase characters or that an
object ID can be expressed uniquely in hex form, neither of which are
currently true.  Git itself normally uses binary object IDs, which
avoids many of these problems, but most other projects deal primarily in
hex object IDs, so they are more affected.

In preparation for Git 3.0, only allow lowercase hex object IDs in
breaking changes mode and document this as well.  Add a new test to
verify we reject new uppercase object IDs.

Signed-off-by: brian m. carlson <sandals@crustytoothpaste.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2026-09-07 14:07:22 -07:00
..
2026-08-03 09:31:30 -07:00
2026-06-15 07:42:00 -07:00
2025-03-01 10:26:15 -08:00
…
2026-06-05 22:27:24 +09:00
2025-12-14 17:04:37 +09:00
2026-03-06 13:02:20 -08:00
2025-02-14 17:53:47 -08:00
2025-12-05 14:49:56 +09:00
2026-05-21 12:06:48 +09:00
2025-12-16 09:42:44 +09:00
…