Re: [PATCH] Add `verify-system` sslmode to use system CA pool for server cert

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Daniel Gustafsson <daniel(at)yesql(dot)se>
Cc: Peter Eisentraut <peter(dot)eisentraut(at)enterprisedb(dot)com>, Jacob Champion <jchampion(at)timescale(dot)com>, "Gregory Stark (as CFM)" <stark(dot)cfm(at)gmail(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org>, Magnus Hagander <magnus(at)hagander(dot)net>, Michael Paquier <michael(at)paquier(dot)xyz>, thomas(at)habets(dot)se, Bruce Momjian <bruce(at)momjian(dot)us>, Andrew Dunstan <andrew(at)dunslane(dot)net>, Jelte Fennema <postgres(at)jeltef(dot)nl>
Subject: Re: [PATCH] Add `verify-system` sslmode to use system CA pool for server cert
Date: 2023-04-13 22:52:20
Message-ID: 1396290.1681426340@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Daniel Gustafsson <daniel(at)yesql(dot)se> writes:
> The attached diff passes the tests on OpenSSL 1.0.1 through 3.1 as well as on
> LibreSSL. Thoughts?

1. You can't assume that errno starts out zero, unless you zero it
right before SSL_connect.

2. I wonder whether it's safe to assume that errno (a/k/a SOCK_ERRNO)
can't be clobbered by SSL_get_verify_result.

3. It seems weird to refer to errno directly just a couple lines away
from where we refer to it via SOCK_ERRNO. Will this even compile
on Windows?

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Thomas Munro 2023-04-13 23:05:41 Re: Wrong results from Parallel Hash Full Join
Previous Message Regina Obe 2023-04-13 22:32:55 RE: [PATCH] Support % wildcard in extension upgrade filenames