Skip to content
This repository was archived by the owner on Apr 26, 2024. It is now read-only.
This repository was archived by the owner on Apr 26, 2024. It is now read-only.

Not whitelisting federation with self breaks federation #4857

@spantaleev

Description

@spantaleev

Description

This is somewhat of a continuation of #4856.

I've got 2 servers with federation enabled. Each server only whitelists the other in federation_domain_whitelist. I'm only expecting them to federate with one another.

When I make a room and invite a user from the other server (inviting by matrix id), Synapse would first try retrieving some signature keys.

As described in #4856, it first attempts to do so using perspectives. This will fail if federation with matrix.org is not enabled.

The server then attempts to federate with itself for some reason.
If our own domain is not listed in federation_domain_whitelist, we'll get a FederationDeniedError error and federation will effectively not work. The invite reaches the other server, but in a broken state - it can neither be accepted, nor rejected. The only solution to fix that up on the other server - deleting it from local_invites and restarting Synapse (maybe this is some other bug that should be reported and worked on?).

I'm not sure what the reason is for needing to federate with self.
If there is a valid reason for doing so, perhaps:

  • our own server_name should automatically (implicitly) get added to federation_domain_whitelist (unless federation_domain_whitelist is None, that is)
  • the comments next to federation_domain_whitelist should be adjusted to indicate such a need

Version information

  • Version: 0.99.2

  • Install method: Docker

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-FederationT-DefectBugs, crashes, hangs, security vulnerabilities, or other reported issues.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions