You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
check_hostname defaults to true when true is invalid #160605
you start getting ValueError: check_hostname requires server_hostname starting in 3.14.8 when the same code worked in 3.14.7.
I understand there was a change made for security reasons. If somebody has enabled check_hostname they expect hostname validation. However, this code does not enable check_hostname. It's being defaulted somewhere. The previous code was intentionally not checking the hostname.
I don't know how common this is. In my case, server_hostname is set to empty because the target service behaves incorrectly if it receives SNI, and hostname validation is not desired because the presented certificate is valid for no names. It's a server certificate, but it uses the client certificate validation pattern where the certificate must be signed by the expected CA.
Hi, I'd like to contribute to investigating this regression.
I plan to create a minimal reproducer, inspect the changes introduced by #156793, and add a regression test.
Before submitting a PR, could a maintainer confirm the intended behavior for server_hostname="" when check_hostname=True? I understand that the change addresses a security issue, so I'd like to ensure any proposed fix preserves the security guarantees while addressing the reported compatibility regression.
Activity
jadhavroshani713-sys commentedon Oct 24, 2026
Hi, I'd like to contribute to investigating this regression.
I plan to create a minimal reproducer, inspect the changes introduced by #156793, and add a regression test.
Before submitting a PR, could a maintainer confirm the intended behavior for
server_hostname=""whencheck_hostname=True? I understand that the change addresses a security issue, so I'd like to ensure any proposed fix preserves the security guarantees while addressing the reported compatibility regression.