dont allow GetRemotePdu server to be ourselves
Signed-off-by: strawberry <strawberry@puppygock.gay>
This commit is contained in:
parent
b0bee8f6ae
commit
935f83af98
1 changed files with 7 additions and 0 deletions
|
@ -1971,6 +1971,13 @@ impl Service {
|
|||
));
|
||||
}
|
||||
|
||||
if server == services().globals.server_name() {
|
||||
return Ok(RoomMessageEventContent::text_plain(
|
||||
"Not allowed to send federation requests to ourselves. Please use `get-pdu` for fetching \
|
||||
local PDUs.",
|
||||
));
|
||||
}
|
||||
|
||||
// TODO: use Futures as some requests may take a while so we dont block the
|
||||
// admin room
|
||||
match services()
|
||||
|
|
Loading…
Add table
Reference in a new issue