matrix-spec/specification/modules/history_visibility.rst

27 lines
841 B
ReStructuredText
Raw Normal View History

2015-09-01 12:53:30 +02:00
Room History Visibility
-----------------------
2015-09-01 12:53:30 +02:00
.. _module:history-visibility:
2015-09-04 12:21:14 +02:00
Whether a member of a room can see the events that happened in a room from
before they joined the room is controlled by the ``history_visibility`` key
of the ``m.room.history_visibility`` state event. The valid values for
``history_visibility`` are:
2015-09-01 12:53:30 +02:00
- ``shared``
- ``invited``
- ``joined``
2015-09-04 12:21:14 +02:00
By default if no ``history_visibility`` is set it is assumed to be ``shared``.
2015-09-01 12:53:30 +02:00
The rules governing whether a user is allowed to see an event depend solely on
2015-09-04 12:21:14 +02:00
the state of the room at that event:
2015-09-01 12:53:30 +02:00
1. If the user was joined, allow.
2. If the user was invited and the ``history_visibility`` was set to
``invited`` or ``shared``, allow.
3. If the user was neither invited nor joined but the ``history_visibility``
was set to ``shared``, allow.
4. Otherwise, deny.