add federation allow list

This commit is contained in:
Jade Ellis 2025-01-18 15:21:55 +00:00
parent eb7d893c86
commit 371103fb35
No known key found for this signature in database
GPG key ID: 8705A2A3EBF77BD2
15 changed files with 101 additions and 94 deletions

View file

@ -1335,12 +1335,22 @@ pub struct Config {
/// sender user's server name, inbound federation X-Matrix origin, and
/// outbound federation handler.
///
/// Additionally, it will hide messages from these servers for all users
/// on this server.
///
/// Basically "global" ACLs.
///
/// default: []
#[serde(default)]
pub forbidden_remote_server_names: HashSet<OwnedServerName>,
/// The inverse of `forbidden_remote_server_names`. By default, allows all
/// servers. `forbidden_remote_server_names` takes precidence.
///
/// default: []
#[serde(default)]
pub allowed_remote_server_names: HashSet<OwnedServerName>,
/// List of forbidden server names that we will block all outgoing federated
/// room directory requests for. Useful for preventing our users from
/// wandering into bad servers or spaces.