Skip to content
This repository has been archived by the owner on Apr 26, 2024. It is now read-only.

Commit

Permalink
Merge pull request #3754 from matrix-org/erikj/fix_whitelist
Browse files Browse the repository at this point in the history
Allow federation_domain_whitelist to be emtpy list
  • Loading branch information
erikjohnston authored Aug 24, 2018
2 parents 92d50e3 + c780d84 commit 84b4e76
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions changelog.d/3754.bugfix
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Fix 'federation_domain_whitelist' such that an empty list correctly blocks all outbound federation traffic
2 changes: 1 addition & 1 deletion synapse/http/matrixfederationclient.py
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ def _request(self, destination, method, path,
failures, connection failures, SSL failures.)
"""
if (
self.hs.config.federation_domain_whitelist and
self.hs.config.federation_domain_whitelist is not None and
destination not in self.hs.config.federation_domain_whitelist
):
raise FederationDeniedError(destination)
Expand Down

0 comments on commit 84b4e76

Please sign in to comment.