Re: Removing --disable-strong-random from the code

2019-01-01 Thread Michael Paquier
On Mon, Dec 31, 2018 at 10:20:28AM +0900, Michael Paquier wrote: > I am attaching an updated patch. I'll do an extra pass on it in the > next couple of days and commit if there is nothing. The diff stats > are nice: > 32 files changed, 60 insertions(+), 1181 deletions(-) And committed. -- Michae

Re: Removing --disable-strong-random from the code

2018-12-31 Thread Michael Paquier
On Mon, Dec 31, 2018 at 10:20:28AM +0900, Michael Paquier wrote: > On Sun, Dec 30, 2018 at 11:47:03AM -0500, Tom Lane wrote: >> Not the fault of this patch, but surely this bit in pgcrypto's >> pad_eme_pkcs1_v15() >> >> if (!pg_strong_random((char *) p, 1)) >> { >>

Re: Removing --disable-strong-random from the code

2018-12-30 Thread Michael Paquier
On Sun, Dec 30, 2018 at 11:47:03AM -0500, Tom Lane wrote: > Michael Paquier writes: > > And attached is an updated patch with all those fixes included. Any > > thoughts or opinions? > > contrib/pgcrypto has some variant expected-files for the no-strong-random > case that could be removed now. >

Re: Removing --disable-strong-random from the code

2018-12-30 Thread Michael Paquier
On Sun, Dec 30, 2018 at 11:56:48AM -0500, Tom Lane wrote: > Oh, one more thought: the removal of the --disable-strong-random > documentation stanza means there's no explanation of what to do > to build on platforms without /dev/urandom. Perhaps something > like this in installation.sgml: > >

Re: Removing --disable-strong-random from the code

2018-12-30 Thread Tom Lane
I wrote: > LGTM otherwise. Oh, one more thought: the removal of the --disable-strong-random documentation stanza means there's no explanation of what to do to build on platforms without /dev/urandom. Perhaps something like this in installation.sgml: - You need OpenSSL, if you want to

Re: Removing --disable-strong-random from the code

2018-12-30 Thread Tom Lane
Michael Paquier writes: > And attached is an updated patch with all those fixes included. Any > thoughts or opinions? contrib/pgcrypto has some variant expected-files for the no-strong-random case that could be removed now. BackendRandomLock should be removed, too. Since pg_strong_random is de

Re: Removing --disable-strong-random from the code

2018-12-30 Thread Michael Paquier
On Sun, Dec 30, 2018 at 04:15:49PM +0900, Michael Paquier wrote: > On Sun, Dec 30, 2018 at 01:45:42AM -0500, Tom Lane wrote: >> Hah, I was just about to work on that myself --- glad I didn't get >> to it quite yet. A couple of thoughts: >> >> 1. Surely there's documentation about --disable-strong

Re: Removing --disable-strong-random from the code

2018-12-29 Thread Michael Paquier
On Sun, Dec 30, 2018 at 01:45:42AM -0500, Tom Lane wrote: > Hah, I was just about to work on that myself --- glad I didn't get > to it quite yet. A couple of thoughts: > > 1. Surely there's documentation about --disable-strong-random > to clean up too? Oops, I forgot to grep on this one. Remov

Re: Removing --disable-strong-random from the code

2018-12-29 Thread Tom Lane
Michael Paquier writes: > Attached is a patch to clean up the code, which removes all the code > specific to random generation for backends (no more shmem code paths > and such), as well as the pg_frontend_random() and > pg_backend_random(). Thoughts or opinions? Hah, I was just about to work on

Removing --disable-strong-random from the code

2018-12-29 Thread Michael Paquier
Hi all As mentioned here, there has been a discussion about $subject and the fact that it may be rather useless: https://www.postgresql.org/message-id/21150.1546010...@sss.pgh.pa.us --disable-strong-random is also untested in the buildfarm. Attached is a patch to clean up the code, which removes