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

Client: Setting a custom SSL verifier discards previous Connector #495

Closed
mlalic opened this issue May 1, 2015 · 1 comment · Fixed by #518
Closed

Client: Setting a custom SSL verifier discards previous Connector #495

mlalic opened this issue May 1, 2015 · 1 comment · Fixed by #518
Labels
A-client Area: client.

Comments

@mlalic
Copy link
Contributor

mlalic commented May 1, 2015

When the Client::set_ssl_verifier method is called, it will discard any previously existing Connector instance that the Client was instantiated to use. This wasn't a problem before, when the connectors were largely stateless, but with the introduction of a Pool connector, this means that the pool's config will be dropped (replaced with the default one) and the client will use a brand new set of connections, instead of the originally intended ones.

@seanmonstar seanmonstar added the A-client Area: client. label May 2, 2015
@seanmonstar
Copy link
Member

This is true. Before, it was possible when Client was generic over the NetworkConnector. Perhaps such a method set_ssl_verifier should be added to the NetworkConnector trait...

mlalic added a commit to mlalic/hyper that referenced this issue May 9, 2015
The client no longer drops the old `Connector` instance, along with its
entire context (such as the settings and pooled connections in the case
of a `Pool` connector); rather, it passes the SSL verifier on to the
`Connector` so that it uses it for any future connections that it needs
to establish.

A regression test is included.

Closes hyperium#495
mlalic added a commit to mlalic/hyper that referenced this issue May 9, 2015
The client no longer drops the old `Connector` instance, along with its
entire context (such as the settings and pooled connections in the case
of a `Pool` connector); rather, it passes the SSL verifier on to the
`Connector` so that it uses it for any future connections that it needs
to establish.

A regression test is included.

Closes hyperium#495
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-client Area: client.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants