You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Our applications always use SSLMode=prefer to connect to databases, including unsecured ones. It works well, but not with secretless-broker. SSLMode=prefer should be a safe option for capability autodetection.
Also, SSLMode=require should send the correct message to the client instead of a generic error.
Steps to Reproduce
$ PGSSLMODE=prefer psql -h localhost -p 55432 -U postgres postgres
psql: could not connect to server: Connection refused
Is the server running on host "localhost" (::1) and accepting
TCP/IP connections on port 55432?
FATAL: SSL not supported
$ PGSSLMODE=require psql -h localhost -p 55432 -U postgres postgres
psql: could not connect to server: Connection refused
Is the server running on host "localhost" (::1) and accepting
TCP/IP connections on port 55432?
FATAL: SSL not supported
Expected Results
Secretless broker should correctly signalize unsupported SSL to the client so the client can continue with an unsecured connection if required.
$ PGSSLMODE=prefer psql -h localhost -p 5432 -U postgres postgres
psql (10.15, server 13.1 (Debian 13.1-1.pgdg100+1))
WARNING: psql major version 10, server major version 13.
Some psql features might not work.
Type "help" for help.
postgres=#
Correct signaling with SSLMode=require
$ PGSSLMODE=require psql -h localhost -p 5432 -U postgres postgres
server does not support SSL, but SSL was required
Actual Results (including error logs, if applicable)
2021/02/05 11:02:37 [DEBUG] pg: New connection on 127.0.0.1:55432.
2021/02/05 11:02:37 [DEBUG] pg: Handling connection 127.0.0.1:59066 -> 127.0.0.1:55432
2021/02/05 11:02:37 [DEBUG] pg: s.Client version: 80877103, (SSL mode: true)
2021/02/05 11:02:37 [ERROR] pg: Failed on handle connection: failed on connect: SSL not supported
Additional Information
This issue blocks us from the next steps in the evaluation process so I prepared a patch that fixes the issue so we can continue.
The text was updated successfully, but these errors were encountered:
Summary
Our applications always use SSLMode=prefer to connect to databases, including unsecured ones. It works well, but not with secretless-broker. SSLMode=prefer should be a safe option for capability autodetection.
Also, SSLMode=require should send the correct message to the client instead of a generic error.
Steps to Reproduce
Expected Results
Secretless broker should correctly signalize unsupported SSL to the client so the client can continue with an unsecured connection if required.
Correct signaling with SSLMode=require
Actual Results (including error logs, if applicable)
Additional Information
This issue blocks us from the next steps in the evaluation process so I prepared a patch that fixes the issue so we can continue.
The text was updated successfully, but these errors were encountered: