Re: Replace current implementations in crypt() and gen_salt() to OpenSSL

From: Joe Conway <mail(at)joeconway(dot)com>
To: Daniel Gustafsson <daniel(at)yesql(dot)se>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, "Koshi Shibagaki (Fujitsu)" <shibagaki(dot)koshi(at)fujitsu(dot)com>, "Hayato Kuroda (Fujitsu)" <kuroda(dot)hayato(at)fujitsu(dot)com>, Peter Eisentraut <peter(at)eisentraut(dot)org>, Robert Haas <robertmhaas(at)gmail(dot)com>, "pgsql-hackers(at)lists(dot)postgresql(dot)org" <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: Replace current implementations in crypt() and gen_salt() to OpenSSL
Date: 2025-01-23 20:42:53
Message-ID: dbe42e13-2989-4dd6-b252-2b4b015c308d@joeconway.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 1/22/25 17:49, Daniel Gustafsson wrote:
>> On 22 Jan 2025, at 19:59, Joe Conway <mail(at)joeconway(dot)com> wrote:
>
>> I found it necessary to add:
>> #include <openssl/crypto.h>
>> in
>> contrib/pgcrypto/openssl.c
>> to avoid a symbol not defined warning.
>
> Makes sense, it doesn't reproduce in my tree but reading OpenSSL code it seems
> very plausible (and clearly happens in your environment).
>
>> Although come to think of it, probably:
>> "use of non-FIPS certified crypto"
>> ^^^^^^^^^
>> should rather say:
>> "use of non-FIPS validated crypto"
>> ^^^^^^^^^
>
> That's probably better yes. I was under the impression that the terminology
> used was "FIPS certified" but reading the OpenSSL and FIPS documentation they
> too use "FIPS validated" so I've switched to that as per your comment.
>
>> FWIW, I tested with non-FIPS (OpenSSL 3.0.13 30 Jan 2024) on Linux Mint 22.1 and FIPS (aws-lc [1][2]) on Amazon Linux 2023.
>
> Thanks. My testing has been with a range of plain upstream OpenSSL trees from
> 1.1.1 to 3.4 (compiled on macOS).
>
> Rebased v10 with the above fixed attached.

LGTM

--
Joe Conway
PostgreSQL Contributors Team
RDS Open Source Databases
Amazon Web Services: https://aws.amazon.com

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Andres Freund 2025-01-23 20:51:04 Re: Orphaned users in PG16 and above can only be managed by Superusers
Previous Message Dagfinn Ilmari Mannsåker 2025-01-23 20:25:45 Re: pg_createsubscriber TAP test wrapping makes command options hard to read.