-
-
Notifications
You must be signed in to change notification settings - Fork 486
Build out SSL testing infrastructure #22
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
Comments
Slightly related, I need to connect to a Heroku based postgres instance and they require to user ssl=require. Haven't found any example here doing it. |
You'd pass |
Ok cool. I don't think there's much to configure (I mean I've used Heroku's postgres from other platform and literally all I needed was to add ssl=require*). I'm having issues using rust-openssl actually. Any chance to find a simple example with SslMode::Require here soon? |
What problems are you having with it? |
Here's what I'm trying to do (newbie alert!):
now to do that I had to add
and also import
and now I'm getting What am I missing? |
use openssl::ssl::SslMethod::Sslv23;
use openssl::ssl::SslContext; |
Awesome! Thanks! |
This doesn't work with with recent versions, I'm using |
@asultanpur enable the |
Sorry for confirming late, it works. Thank you. |
disclaimer: I'm new to rust (3 days). so I may misunderstand very fundamental thing. I cannot get compiled ssl-enabled mode initialization. its almost like following:
Im using 0.10, and I add openssl feature to Cargo.toml like that.
then compiler reports following error:
seems openssl feature does not have effect. (src/io/mod.rs) but even if I also try feature flag to cargo directly
same error reports again. am I missing something? thanks in advance. |
You'll want to make sure your Cargo.toml activates rust-postgres's openssl feature. For example [features]
my_ssl_feature = ["openssl", "postgres/openssl"] |
hi, I manage to compile my code. thank you for your quick response! spend happy X'mas :D |
Awesome! |
* add ready_status on simple queries * add correct socket2 features
* add ready_status on simple queries * add correct socket2 features
We should really be running Postgres both with SSL on and off to fully test the different
SslMode
s.The text was updated successfully, but these errors were encountered: