8000 crashes when connecting over TLS using OpenSSL v3.2 · Issue #80 · smashedtoatoms/asdf-postgres · GitHub
[go: up one dir, main page]

Skip to content
crashes when connecting over TLS using OpenSSL v3.2 #80
@cbortz

Description

@cbortz

Describe the bug

Commands such as psql and pg_dump crash when connecting with TLS using openssl v3.2+. The error is:

pg_dump: error: connection to server at "<REDACTED URL>" (<REDACTED IP>), port <REDACTED PORT> failed: FATAL:  no PostgreSQL user name specified in startup packet
connection to server at "<REDACTED URL>" (<REDACTED IP>), port <REDACTED PORT> failed: FATAL:  no PostgreSQL user name specified in startup packet
pg_dump(62804,0x1d7ef1000) malloc: *** error for object 0x2a: pointer being freed was not allocated
pg_dump(62804,0x1d7ef1000) malloc: *** set a breakpoint in malloc_error_break to debug

Steps to reproduce

  1. Install openssl v3.2+ (using MacOS, I installed via homebrew)
  2. Install postgres via asdf-postgres
  3. attempt to connect to a secure postgres URL using a connection string with the username and password included in the URL

Expected behavior

A successful connection to the server (or a successful dump is using pg_dump)

Additional context

A temporary workaround is downgrading to openssl 3.1.x. I have personally confirmed that this works (but introduces some other issues).

The PostgreSQL package for Homebrew (MacOS) had a similar issue that they patched:

There was also a thread on postgresql.org: SSL tests fail on OpenSSL v3.2.0

Their fix references compatibility issues with libpq as well.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0