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

Commit 332cce8

Browse files
Disable device name lookup over federation by default (#12616)
1 parent ba3fd54 commit 332cce8

File tree

5 files changed

+24
-12
lines changed

5 files changed

+24
-12
lines changed

changelog.d/12616.misc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Prevent remote homeservers from requesting local user device names by default.

docs/sample_config.yaml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -709,11 +709,11 @@ retention:
709709
#
710710
#allow_profile_lookup_over_federation: false
711711

712-
# Uncomment to disable device display name lookup over federation. By default, the
713-
# Federation API allows other homeservers to obtain device display names of any user
714-
# on this homeserver. Defaults to 'true'.
712+
# Uncomment to allow device display name lookup over federation. By default, the
713+
# Federation API prevents other homeservers from obtaining the display names of
714+
# user devices on this homeserver. Defaults to 'false'.
715715
#
716-
#allow_device_name_lookup_over_federation: false
716+
#allow_device_name_lookup_over_federation: true
717717

718718

719719
## Caching ##

docs/upgrade.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -89,6 +89,17 @@ process, for example:
8989
dpkg -i matrix-synapse-py3_1.3.0+stretch1_amd64.deb
9090
```
9191
92+
# Upgrading to v1.59.0
93+
94+
## Device name lookup over federation has been disabled by default
95+
96+
The names of user devices are no longer visible to users on other homeservers by default.
97+
Device IDs are unaffected, as these are necessary to facilitate end-to-end encryption.
98+
99+
To re-enable this functionality, set the
100+
[`allow_device_name_lookup_over_federation`](https://matrix-org.github.io/synapse/v1.59/usage/configuration/config_documentation.html#federation)
101+
homeserver config option to `true`.
102+
92103
# Upgrading to v1.58.0
93104
94105
## Groups/communities feature has been disabled by default

docs/usage/configuration/config_documentation.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1035,13 +1035,13 @@ allow_profile_lookup_over_federation: false
10351035
---
10361036
Config option: `allow_device_name_lookup_over_federation`
10371037

1038-
Set this option to false to disable device display name lookup over federation. By default, the
1039-
Federation API allows other homeservers to obtain device display names of any user
1038+
Set this option to true to allow device display name lookup over federation. By default, the
1039+
Federation API prevents other homeservers from obtaining the display names of any user devices
10401040
on this homeserver.
10411041

10421042
Example configuration:
10431043
```yaml
1044-
allow_device_name_lookup_over_federation: false
1044+
allow_device_name_lookup_over_federation: true
10451045
```
10461046
---
10471047
## Caching ##

synapse/config/federation.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ def read_config(self, config: JsonDict, **kwargs: Any) -> None:
4646
)
4747

4848
self.allow_device_name_lookup_over_federation = config.get(
49-
"allow_device_name_lookup_over_federation", True
49+
"allow_device_name_lookup_over_federation", False
5050
)
5151

5252
def generate_config_section(self, **kwargs: Any) -> str:
@@ -81,11 +81,11 @@ def generate_config_section(self, **kwargs: Any) -> str:
8181
#
8282
#allow_profile_lookup_over_federation: false
8383
84-
# Uncomment to disable device display name lookup over federation. By default, the
85-
# Federation API allows other homeservers to obtain device display names of any user
86-
# on this homeserver. Defaults to 'true'.
84+
# Uncomment to allow device display name lookup over federation. By default, the
85+
# Federation API prevents other homeservers from obtaining the display names of
86+
# user devices on this homeserver. Defaults to 'false'.
8787
#
88-
#allow_device_name_lookup_over_federation: false
88+
#allow_device_name_lookup_over_federation: true
8989
"""
9090

9191

0 commit comments

Comments
 (0)