diff --git a/synapse/crypto/context_factory.py b/synapse/crypto/context_factory.py index 6fda5e677d..6ebbd3b73c 100644 --- a/synapse/crypto/context_factory.py +++ b/synapse/crypto/context_factory.py @@ -145,7 +145,10 @@ class ClientTLSOptionsFactory(object): should_verify = self._config.federation_verify_certificates # Check if we've disabled certificate verification for this host - if should_verify and host in self._config.federation_certificate_verification_whitelist: + if ( + should_verify and + host in self._config.federation_certificate_verification_whitelist + ): should_verify = False if should_verify: