mirror of
https://github.com/postgres/postgres.git
synced 2025-07-27 12:41:57 +03:00
Remove configure switch --disable-strong-random
This removes a portion of infrastructure introduced by fe0a0b5
to allow
compilation of Postgres in environments where no strong random source is
available, meaning that there is no linking to OpenSSL and no
/dev/urandom (Windows having its own CryptoAPI). No systems shipped
this century lack /dev/urandom, and the buildfarm is actually not
testing this switch at all, so just remove it. This simplifies
particularly some backend code which included a fallback implementation
using shared memory, and removes a set of alternate regression output
files from pgcrypto.
Author: Michael Paquier
Reviewed-by: Tom Lane
Discussion: https://postgr.es/m/20181230063219.GG608@paquier.xyz
This commit is contained in:
@ -34,7 +34,6 @@
|
||||
#include "px.h"
|
||||
#include "px-crypt.h"
|
||||
|
||||
#include "utils/backend_random.h"
|
||||
|
||||
static char *
|
||||
run_crypt_des(const char *psw, const char *salt,
|
||||
@ -153,7 +152,7 @@ px_gen_salt(const char *salt_type, char *buf, int rounds)
|
||||
return PXE_BAD_SALT_ROUNDS;
|
||||
}
|
||||
|
||||
if (!pg_backend_random(rbuf, g->input_len))
|
||||
if (!pg_strong_random(rbuf, g->input_len))
|
||||
return PXE_NO_RANDOM;
|
||||
|
||||
p = g->gen(rounds, rbuf, g->input_len, buf, PX_MAX_SALT_LEN);
|
||||
|
Reference in New Issue
Block a user