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

Tightening the runtime type check for ssl (#7698) #8042

Commits on Jan 20, 2024

  1. Tightening the runtime type check for ssl (#7698)

    Currently, the valid types of ssl parameter are SSLContext,
    Literal[False], Fingerprint or None.
    
    If user sets ssl = False, we disable ssl certificate validation which
    makes total sense. But if user set ssl = True by mistake, instead of
    enabling ssl certificate validation or raising errors, we silently
    disable the validation too which is a little subtle but weird.
    
    In this PR, we added a check that if user sets ssl=True, we enable
    certificate validation by treating it as using Default SSL Context.
    
    ---------
    
    Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
    Co-authored-by: Sviatoslav Sydorenko <wk.cvs.github@sydorenko.org.ua>
    Co-authored-by: Sam Bull <aa6bs0@sambull.org>
    Co-authored-by: J. Nick Koston <nick@koston.org>
    Co-authored-by: Sam Bull <git@sambull.org>
    (cherry picked from commit 9e14ea1)
    xiangyan99 authored and Dreamsorcerer committed Jan 20, 2024
    Copy the full SHA
    e46294a View commit details
    Browse the repository at this point in the history
  2. Copy the full SHA
    ed86b27 View commit details
    Browse the repository at this point in the history
  3. Update client_reqrep.py

    Dreamsorcerer committed Jan 20, 2024
    Copy the full SHA
    37ac9cf View commit details
    Browse the repository at this point in the history
  4. Update client_reqrep.py

    Dreamsorcerer committed Jan 20, 2024
    Copy the full SHA
    30cc724 View commit details
    Browse the repository at this point in the history
  5. Copy the full SHA
    045ec4b View commit details
    Browse the repository at this point in the history
  6. Copy the full SHA
    47ed9fe View commit details
    Browse the repository at this point in the history