> On 24 Aug 2023, at 10:11, Sergey Shinderuk <s.shinderuk@postgrespro.ru> wrote:
>
> On 23.08.2023 16:23, Daniel Gustafsson wrote:
>>> On 1 Aug 2023, at 16:44, Sergey Shinderuk <s.shinderuk@postgrespro.ru> wrote:
>>> A static analyzer reported a possible pfree(NULL) in be_tls_open_server().
>> This has the smell of a theoretical problem, I can't really imagine a
>> certificate where which would produce this. Have you been able to trigger it?
>
> I triggered a crash by generating a certificate without a CN and forcing malloc to return NULL when called from
X509_NAME_print_exor BIO_get_mem_ptr with gdb.
Can you extend the patch with that certificate and a test using it? The
certificates are generated from config files kept in the repo in src/test/ssl
in order to be reproducible.
--
Daniel Gustafsson