diff options
author | Brendan Abolivier <babolivier@matrix.org> | 2022-01-28 14:41:33 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-01-28 15:41:33 +0100 |
commit | bf60da1a60096fac5fb778b732ff2214862ac808 (patch) | |
tree | 494a272a37f8d6ce5be677d5bc828a652b440c58 /docs/sample_config.yaml | |
parent | Pass `isolation_level` to `runWithConnection` (#11847) (diff) | |
download | synapse-bf60da1a60096fac5fb778b732ff2214862ac808.tar.xz |
Configurable limits on avatars (#11846)
Only allow files which file size and content types match configured limits to be set as avatar. Most of the inspiration from the non-test code comes from matrix-org/synapse-dinsic#19
Diffstat (limited to 'docs/sample_config.yaml')
-rw-r--r-- | docs/sample_config.yaml | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/docs/sample_config.yaml b/docs/sample_config.yaml index abf28e4490..689b207fc0 100644 --- a/docs/sample_config.yaml +++ b/docs/sample_config.yaml @@ -471,6 +471,20 @@ limit_remote_rooms: # #allow_per_room_profiles: false +# The largest allowed file size for a user avatar. Defaults to no restriction. +# +# Note that user avatar changes will not work if this is set without +# using Synapse's media repository. +# +#max_avatar_size: 10M + +# The MIME types allowed for user avatars. Defaults to no restriction. +# +# Note that user avatar changes will not work if this is set without +# using Synapse's media repository. +# +#allowed_avatar_mimetypes: ["image/png", "image/jpeg", "image/gif"] + # How long to keep redacted events in unredacted form in the database. After # this period redacted events get replaced with their redacted form in the DB. # |