From 9d8ecc9e6c48b9dfc0b41326794b8e10fc6ad062 Mon Sep 17 00:00:00 2001 From: Andrew Morgan <1342360+anoadragon453@users.noreply.github.com> Date: Thu, 30 Apr 2020 11:38:07 +0100 Subject: Apply federation check for /publicRooms with filter list (#7367) --- changelog.d/7367.bugfix | 1 + synapse/handlers/room_list.py | 6 +++++- 2 files changed, 6 insertions(+), 1 deletion(-) create mode 100644 changelog.d/7367.bugfix diff --git a/changelog.d/7367.bugfix b/changelog.d/7367.bugfix new file mode 100644 index 0000000000..12171d4e1c --- /dev/null +++ b/changelog.d/7367.bugfix @@ -0,0 +1 @@ +Prevent non-federating rooms from appearing in responses to federated `POST /publicRoom` requests when a filter was included. diff --git a/synapse/handlers/room_list.py b/synapse/handlers/room_list.py index 59c9906b31..e75dabcd77 100644 --- a/synapse/handlers/room_list.py +++ b/synapse/handlers/room_list.py @@ -90,7 +90,11 @@ class RoomListHandler(BaseHandler): logger.info("Bypassing cache as search request.") return self._get_public_room_list( - limit, since_token, search_filter, network_tuple=network_tuple + limit, + since_token, + search_filter, + network_tuple=network_tuple, + from_federation=from_federation, ) key = (limit, since_token, network_tuple) -- cgit 1.4.1