public inbox for git@vger.kernel.org
 help / color / mirror / Atom feed
From: Todd Zullinger <tmz@pobox.com>
To: Justin Tobler <jltobler@gmail.com>
Cc: git@vger.kernel.org, Junio C Hamano <gitster@pobox.com>
Subject: Re: [PATCH] t: avoid git config syntax from newer releases
Date: Wed, 9 Jul 2025 12:08:07 -0400	[thread overview]
Message-ID: <aG6T5ylikwrGEEo2@teonanacatl.net> (raw)
In-Reply-To: <iuravzuqoqagie37is72e773zufuxcedwnc4i6ehhklpszg25t@bzu66havljcq>

Justin Tobler wrote:
> On 25/07/08 05:05PM, Todd Zullinger wrote:
>> In a recent security release, 05e9cd64ee (config: quote values
>> containing CR character, 2025-05-19) added calls to `git config get`,
>> `git config set`, and `git config unset` which are not present on the
>> maint-2.43 branch.
>> 
>> These subcommands were added in the following commits, released in
>> git-2.46.0:
>> 
>>   4e51389000 (builtin/config: introduce "get" subcommand, 2024-05-06),
>>   00bbdde141 (builtin/config: introduce "set" subcommand, 2024-05-06),
>>   95ea69c67b (builtin/config: introduce "unset" subcommand, 2024-05-06)
>> 
>> Revert to the previous `git config` syntax for older maintenance
>> branches.
> 
> Thanks for raising this fix! Apologies, it slipped my mind that the
> config subsommands wouldn't be available on older versions.

No worries.  Thanks for working on these CVE fixes!

I thought that the CI might catch those failures, but I
imagine they slipped past others as easily as some other
failures slipped past me last night.

There are unrelated test failures on those older maint
branches which make noticing any new test failures less
likely.  Even more so when you're working on a security
issue and there is less time and fewer eyes on some of the
less important details. :)

I looked at a couple of the failed jobs at the time and they
were unrelated to the tests I'd changed.  I incorrectly
presumed that was the reason for all of the failures.

A few (linux-leaks (ubuntu-latest), linux-reftable-leaks
(ubuntu-latest) failed t7450.50 (submodule must not checkout
into different directory) with:

  + printf sub\r
  + git -C repo mv sub sub
  Aborted (core dumped)
  error: last command exited with $?=134
  + rm -rf sub repo bad-clone
  + exit 134
  + eval_ret=134
  + :
  not ok 50 - submodule must not checkout into different directory

I don't know if that is worth looking at, given the age of
these maint branches.

While I was poking though, here are the other failures from
the maint-2.45 branch runs at GitHub:

Several jobs (linux-musl (alpine), osx-gcc (macos-13))
failed in imap-send.c and http.c, with:

    call to '_curl_easy_setopt_err_long' declared with
    attribute warning: curl_easy_setopt expects a long
    argument [-Werror=attribute-warning]

I think this has been fixed in later releases.  It rings a
tiny bell, anyway.

The 'pedantic (fedora)' and 'win build' jobs both failed
with:

  Error: object-file.c:58:9: initializer-string for array of
  'unsigned char' truncates NUL terminator but destination
  lacks 'nonstring' attribute (33 chars into 32 available)
  [-Werror=unterminated-string-initialization]
     58 |         "\x47\x3a\x0f\x4c\x3b\xe8\xa9\x36\x81\xa2" \
        |         ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  object-file.c:80:17: note: in expansion of macro 'EMPTY_BLOB_SHA256_BIN_LITERAL'
     80 |         .hash = EMPTY_BLOB_SHA256_BIN_LITERAL,
        |                 ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~

which I presume is also fixed in later releases and may not
be worth fixing on these old maintenance branches.

> The changes here look good to me. :)

Thanks for the extra eyes.

-- 
Todd

      reply	other threads:[~2025-07-09 16:08 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-07-08 17:01 [ANNOUNCE] Git v2.50.1 and friends Junio C Hamano
2025-07-08 20:28 ` Todd Zullinger
2025-07-08 21:05   ` [PATCH] t: avoid git config syntax from newer releases Todd Zullinger
2025-07-08 22:08     ` Junio C Hamano
2025-07-09 14:30     ` Justin Tobler
2025-07-09 16:08       ` Todd Zullinger [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=aG6T5ylikwrGEEo2@teonanacatl.net \
    --to=tmz@pobox.com \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    --cc=jltobler@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox