mirror of
https://git.postgresql.org/git/postgresql.git
synced 2026-02-12 09:27:04 +08:00
Remove incidental md5() function uses from main regression tests
Most of these calls were to generate some random data. These can be replaced by appropriately adapted sha256() calls. To keep the diff smaller, we wrap this into a helper function that produces the same output format and length as the md5() call. This will eventually allow these tests to pass in OpenSSL FIPS mode (which does not allow MD5 use). Similar work for other test suites will follow later. Reviewed-by: Tom Lane <tgl@sss.pgh.pa.us> Discussion: https://www.postgresql.org/message-id/flat/dbbd927f-ef1f-c9a1-4ec6-c759778ac852@enterprisedb.com
This commit is contained in:
@ -2877,7 +2877,7 @@ create type record_type as (x text, y int, z boolean);
|
||||
|
||||
create or replace function ret_query2(lim int) returns setof record_type as $$
|
||||
begin
|
||||
return query select md5(s.x::text), s.x, s.x > 0
|
||||
return query select fipshash(s.x::text), s.x, s.x > 0
|
||||
from generate_series(-8, lim) s (x) where s.x % 2 = 0;
|
||||
end;
|
||||
$$ language plpgsql;
|
||||
|
||||
Reference in New Issue
Block a user