[Bug libc/15813] Multiple issues in __gen_tempname

jakub at redhat dot com sourceware-bugzilla@sourceware.org
Wed Sep 9 09:51:19 GMT 2020


https://sourceware.org/bugzilla/show_bug.cgi?id=15813

--- Comment #7 from Jakub Jelinek <jakub at redhat dot com> ---
Perhaps upon the first EEXIST it could getrandom (with GRND_NONBLOCK) and from
that decide the addend to be used instead of 7777 and use RANDOM_BITS only
before the loop as the base?  The code should make sure the addend isn't
something like 0 or that would cause only very few possibilities in the TMP_MAX
attempts.  And/or the addend could change every few hundred attempts.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


More information about the Glibc-bugs mailing list