fix: Properly check forbidden_remote_server_names for incoming requests

This commit is contained in:
Ginger authored and Ellis Git committed 2026-05-21 12:11:03 +00:00
1 parent d5fc81d39e
commit 185f8c42dc
2 files changed
+16 -9

No files matched your search

+1 -5
View File
@@ -105,11 +105,7 @@ pub(crate) async fn banned_room_check(
return Err!(Request(Forbidden("This room is banned on this homeserver.")));
}
} else if let Some(server_name) = server_name {
if services
.config
.forbidden_remote_server_names
.is_match(server_name.host())
{
if services.moderation.is_remote_server_forbidden(server_name) {
warn!(
"User {user_id} who is not an admin tried joining a room which has the server \
name {server_name} that is globally forbidden. Rejecting.",