git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH 12/12] config.mak.uname: add a note about CSPRNG_METHOD for Linux

From
Ramsay Jones <ramsay@ramsayjones.plus.com>
Date
Mar 20, 2025, 16:41 UTC
Message-ID
<3267c1be-5749-4220-90d8-22aabb631823@ramsayjones.plus.com>
In-Reply-To
<Z9ulomq1tDrZRsmL@pks.im>

On 20/03/2025 05:20, Patrick Steinhardt wrote: [snip]

>> That was my immediate thought also. :)
> 
> Okay. Will you pick it up in v2 of this patch series?

Heh, well, that was my immediate thought, but having thought some more, and considering Brian's earlier email response, I have thought again. ;)

Without a wholesale change to the logic (in order to make it platform siloed), it is probably best to just set the Linux default to 'getrandom'. (I can override in config.mak for my tests, or just ignore that difference now I know :) ).

The issue is that each platform has a different priority order for the 'backends' (even multiple orders depending on the criteria, eg. availability, performance), so the current order is probably fine on newer Linux systems. However, to cater to older systems, it would be best to default to getrandom.

[Note cygwin and *BSD systems should prefer arc4random, on Linux all of the three main options (arc4random, getrandom, getentropy) are pretty much the same from a performance perspective, but getrandom is much more 'available'].

So, yes, a v2 of the series, but a different final patch.

ATB, Ramsay Jones

Previous: Patrick SteinhardtNext: Ramsay Jones
Message 8 of 10 in “config.mak.uname: add a note about CSPRNG_METHOD for Linux”
  1. 12/12 config.mak.uname: add a note about CSPRNG_METHOD for LinuxRamsay Jones, Mar 15, 2025
  2. brian m. carlsonMar 16, 2025
  3. Junio C HamanoMar 16, 2025
  4. Ramsay JonesMar 16, 2025
  5. Patrick SteinhardtMar 19, 2025
  6. Ramsay JonesMar 20, 2025
  7. Patrick SteinhardtMar 20, 2025
  8. Ramsay JonesMar 20, 2025
  9. Ramsay JonesMar 16, 2025
  10. brian m. carlsonMar 16, 2025

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.