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

Fix urllib3 warning #336

Merged
merged 5 commits into from Oct 24, 2022
Merged

Fix urllib3 warning #336

merged 5 commits into from Oct 24, 2022

Commits on Oct 24, 2022

  1. Fix x509 tests by using trustme

    This way the certificate won't be able to expire anymore and we won't
    have to store a blob in git. trustme only supports PEM, not DER, which
    is why test_x509_der has to re-export the certificate and key to DER.
    
    Additionally, since trustme does not support password-protected keys,
    the re-export was the perfect place to add a password, so test_x509_der
    also tests the password case, while it was test_x509_pem until now.
    
    The tests are still not end-to-end, we're just running the x509.py code
    without actually establishing a TLS connection. This could be fixed at a
    later point, but is considered out of scope here as that would be a new
    feature.
    pquentin committed Oct 24, 2022
    Configuration menu
    Copy the full SHA
    b93b406 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    06f1053 View commit details
    Browse the repository at this point in the history
  3. Fix urllib3 warning with conditional import

    This will fix the warning for urllib3 1.26.x. To support urllib3
    2.x we will need to vendor PyOpenSSLContext instead.
    pquentin committed Oct 24, 2022
    Configuration menu
    Copy the full SHA
    19b3990 View commit details
    Browse the repository at this point in the history
  4. Fix F822 flake8 error

    pquentin committed Oct 24, 2022
    Configuration menu
    Copy the full SHA
    6d25425 View commit details
    Browse the repository at this point in the history
  5. Fix tests by removing outdated test_compat.py

    There is no point in adapting that test since importing adapters.x509
    already requires pyOpenSSL. However, the noopenssl tox configuration is
    still useful as we want to make sure the rest of the test suite does run
    without pyOpenSSL.
    pquentin committed Oct 24, 2022
    Configuration menu
    Copy the full SHA
    0a3356d View commit details
    Browse the repository at this point in the history