git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
From: "René Scharfe" <l.s.r@web.de>
To: Junio C Hamano <gitster@pobox.com>,
	"brian m. carlson" <sandals@crustytoothpaste.net>
Cc: git@vger.kernel.org, "Ævar Arnfjörð Bjarmason" <avarab@gmail.com>
Subject: Re: What's cooking in git.git (Jan 2022, #07; Mon, 24)
Date: Fri, 4 Feb 2022 18:27:55 +0100	[thread overview]
Message-ID: <deaf8988-f831-b924-77d7-4973473846d8@web.de> (raw)
In-Reply-To: <xmqqiltvpjc7.fsf@gitster.g>

Am 04.02.22 um 01:27 schrieb Junio C Hamano:
> "brian m. carlson" <sandals@crustytoothpaste.net> writes:
>
>>> * bc/csprng-mktemps (2022-01-17) 2 commits
>>>  - wrapper: use a CSPRNG to generate random file names
>>>  - wrapper: add a helper to generate numbers from a CSPRNG
>>>
>>>  Pick a better random number generator and use it when we prepare
>>>  temporary filenames.
>>>
>>>  Are we solving the right problem?
>>>  cf. <220118.86zgntpegy.gmgdl@evledraar.gmail.com>
>>>  source: <20220117215617.843190-1-sandals@crustytoothpaste.net>
>>
>> It sounds like folks would prefer we drop this series.  I'm not planning
>> to send an alternate approach here.
>
> I personally am OK with these two patches, by the way.  There was an
> interesting thought experiment to see if we can only rely on
> mkstemp() and mkdtemp() that we assume are already secure enough,
> but swapping the not-particularly-good linear conguential generator
> used in git_mkstemps_mode() with a better algorithm that is
> externally supported, making the security issue somebody else's
> problem, is a good incremental improvement, I would think.

We can use mkdtemp(3) in diff.c to get rid of the prefix currently added
to temporary filenames, but using mkstemp(3) to create files with custom
permissions with proper umask(2) handling is painful.  Replacing the RNG
in git_mkstemps_mode(), as this series does, is simpler overall.

> Unless I hear differently from others, I am planning to mark the
> topic for 'next' in my draft of the "What's cooking" report.

Great!

René

  reply	other threads:[~2022-02-04 17:28 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-01-24 19:39 What's cooking in git.git (Jan 2022, #07; Mon, 24) Junio C Hamano
2022-01-25 19:45 ` Submodule UX overhaul update (was: What's cooking in git.git (Jan 2022, #07; Mon, 24)) Emily Shaffer
2022-01-26 14:09   ` Ævar Arnfjörð Bjarmason
2022-01-26 17:27     ` Emily Shaffer
2022-01-26 15:16   ` Kaartic Sivaraam
2022-01-26 16:35   ` Atharva Raykar
2022-01-26 17:43     ` Emily Shaffer
2022-01-26 17:50     ` Glen Choo
2022-01-28  7:40 ` ps/avoid-unnecessary-hook-invocation-with-packed-refs (Was: " Patrick Steinhardt
2022-01-28 21:14   ` ps/avoid-unnecessary-hook-invocation-with-packed-refs Junio C Hamano
2022-01-31  9:50     ` flags types/names (was: ps/avoid-unnecessary-hook-invocation-with-packed-refs) Han-Wen Nienhuys
2022-01-31 17:13       ` flags types/names Junio C Hamano
2022-01-28 22:31 ` What's cooking in git.git (Jan 2022, #07; Mon, 24) brian m. carlson
2022-02-04  0:27   ` Junio C Hamano
2022-02-04 17:27     ` René Scharfe [this message]
2022-02-02 11:28 ` ab/auto-detect-zlib-compress2 (was: What's cooking in git.git (Jan 2022, #07; Mon, 24)) Ævar Arnfjörð Bjarmason

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

  List information: http://vger.kernel.org/majordomo-info.html

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

  git send-email \
    --in-reply-to=deaf8988-f831-b924-77d7-4973473846d8@web.de \
    --to=l.s.r@web.de \
    --cc=avarab@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    --cc=sandals@crustytoothpaste.net \
    /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.
Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).