This is the mail archive of the mailing list for the glibc project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] posix: Fix __gen_tempname iteration entropy (BZ#15813)

Le jeudi 04 avril 2019 à 15:31 +0700, a
écrit :
> From: Adhemerval Zanella <>
> Patch "Do not use HP_TIMING_NOW for random bits (359653aaacad4)"
> fixed
> mostly of the __gen_tempname issues described by BZ#15813. This patch
> fixes the remaining one by adding a extra call to random_bits for
> eac iteration while trying to create the random name.
> The patch also cleanups the tempname implementation since now it
> deviates from gnulib counterpart.
> Checked on powerpc64le-linux-gnu.
> 	[BZ #15813]
> 	* sysdeps/posix/tempname.c: Remove ununsed includes, redundant
> 	definitions, and defines used only for gnulib.
> 	(__gen_tempname): Set number of attemps to TMP_MAX and use
> 	random_bits on eachh iteration.
> ---
>  ChangeLog                |  8 ++++
>  sysdeps/posix/tempname.c | 97 ++++--------------------------------
> ----
>  2 files changed, 17 insertions(+), 88 deletions(-)

For easier review (and maintenance) I would like this patch to be split
in 2 or more patches. At least: one for removing gnulib support, and
one to improve randomness for each retry.


Yann Droneaud

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]