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

Rustls 0.20 and HttpsConnectorBuilder #156

Merged
merged 6 commits into from
Nov 15, 2021
Merged

Rustls 0.20 and HttpsConnectorBuilder #156

merged 6 commits into from
Nov 15, 2021

Commits on Nov 6, 2021

  1. Upgrade to rustls 0.20

    djc authored and g2p committed Nov 6, 2021
    Configuration menu
    Copy the full SHA
    946e0ac View commit details
    Browse the repository at this point in the history
  2. Updates for released versions of rustls 0.20 and rustls-native-certs 0.6

    Convenience functions for rustls client configuration are now in a
    ConfigBuilderExt trait extending rustls::ConfigBuilder.
    
    Disables sct validation with certificate transparency logs, which can't
    be enabled (in a way that would be as compatible as chromium) without a
    bunch of intrusive policies to deal with validity/expiration.
    
    Parts of ConfigBuilderExt::with_native_roots come from
    rustls::RootCertStore::add_parsable_certificates, which cannot be
    used directly due to a newtype in rustls-native-certs.
    g2p committed Nov 6, 2021
    Configuration menu
    Copy the full SHA
    29493f0 View commit details
    Browse the repository at this point in the history

Commits on Nov 8, 2021

  1. Add HttpsConnectorBuilder

    This gives more control over various rustls features,
    as well as ensures that enabling connector features
    like http1/http2 can only be done when the appropriate
    crate features are enabled.
    g2p committed Nov 8, 2021
    Configuration menu
    Copy the full SHA
    5ff82f0 View commit details
    Browse the repository at this point in the history
  2. Expose and forward rustls default features

    tls12 and logging are rustls features we enable by default,
    as does rustls, exposing them explicitly allows users
    to disable them by disabling hyper-rustls default features.
    
    Make sure tests run with tls12 by enabling it in dev-dependencies,
    because windows tests (at least in CI) seem to run with an outdated
    version of curl that doesn't support TLS 1.3.
    g2p committed Nov 8, 2021
    Configuration menu
    Copy the full SHA
    413b73a View commit details
    Browse the repository at this point in the history

Commits on Nov 14, 2021

  1. Update to take advantage of rustls 0.21.1

    The extensions to rustls::ClientConfig in ClientConfigExt
    that set root certificates now do just that, they don't go on to
    configure / disable client auth.
    
    The builder traits are unchanged, they set convenient defaults
    (no client auth) but allow passing a custom rustls::ClientConfig.
    g2p committed Nov 14, 2021
    Configuration menu
    Copy the full SHA
    3274612 View commit details
    Browse the repository at this point in the history
  2. builder: Require alpn_protocols to be empty when passing ClientConfig

    This is the default for a rustls ClientConfig.  We assert this
    to be future proof in case we want to extend the interface by
    handling pre-defined alpn_protocols later.
    g2p committed Nov 14, 2021
    Configuration menu
    Copy the full SHA
    9c32bc3 View commit details
    Browse the repository at this point in the history