Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add secure parameter to Connectors to simplify TLS. #122

Open
jwp opened this issue Feb 5, 2023 · 1 comment
Open

Add secure parameter to Connectors to simplify TLS. #122

jwp opened this issue Feb 5, 2023 · 1 comment
Labels

Comments

@jwp
Copy link
Contributor

jwp commented Feb 5, 2023

With the deprecation of ssl.wrap_socket, carrying TLS arguments makes little sense and is inappropriately limiting.

Provide an alternative to the ssl* parameters (excluding sslmode) with a single secure parameter. Where secure will provide the entire functionality required by python.socket.SocketFactory.secure. Users will pass the wrap_socket method of the SSLContext they (already) configured as the secure keyword.

Possible separate patch: make this usable with postgresql.open indicators, by adding a security dictionary to postgresql.sys where applications may configure the set of secure functions used. postgresql.open("pq://user@host/database?[security]=tls-context-name")?

@jwp
Copy link
Contributor Author

jwp commented Feb 10, 2023

Allow postgresql.open to select the security context using the host and port as the key in the sys.security dictionary?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant