check allow_federation in send_federation_request
Signed-off-by: strawberry <strawberry@puppygock.gay>
This commit is contained in:
parent
4c841cd909
commit
1ecbf55d68
1 changed files with 4 additions and 0 deletions
|
@ -647,6 +647,10 @@ impl Service {
|
||||||
where
|
where
|
||||||
T: OutgoingRequest + Debug,
|
T: OutgoingRequest + Debug,
|
||||||
{
|
{
|
||||||
|
if !services().globals.allow_federation() {
|
||||||
|
return Err(Error::bad_config("Federation is disabled."));
|
||||||
|
}
|
||||||
|
|
||||||
if destination.is_ip_literal() || IPAddress::is_valid(destination.host()) {
|
if destination.is_ip_literal() || IPAddress::is_valid(destination.host()) {
|
||||||
info!(
|
info!(
|
||||||
"Destination {} is an IP literal, checking against IP range denylist.",
|
"Destination {} is an IP literal, checking against IP range denylist.",
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue