Package io.github.ma1uta.matrix.event
Class RoomServerAcl
- java.lang.Object
-
- io.github.ma1uta.matrix.event.Event<C>
-
- io.github.ma1uta.matrix.event.RoomEvent<C>
-
- io.github.ma1uta.matrix.event.StateEvent<RoomServerAclContent>
-
- io.github.ma1uta.matrix.event.RoomServerAcl
-
public class RoomServerAcl extends StateEvent<RoomServerAclContent>
An event to indicate which servers are permitted to participate in the room. Server ACLs may allow or deny groups of hosts. All servers participating in the room, including those that are denied, are expected to uphold the server ACL. Servers that do not uphold the ACLs MUST be added to the denied hosts list in order for the ACLs to remain effective.
The allow and deny lists are lists of globs supporting ? and * as wildcards. When comparing against the server ACLs, the suspect server's port number must not be considered. Therefore evil.com, evil.com:8448, and evil.com:1234 would all match rules that apply to evil.com, for example.
The ACLs are applied to servers when they make requests, and are applied in the following order:- If there is no m.room.server_acl event in the room state, allow.
- If the server name is an IP address (v4 or v6) literal, and allow_ip_literals is present and false, deny.
- If the server name matches an entry in the deny list, deny.
- If the server name matches an entry in the allow list, allow.
- Otherwise, deny.
-
-
Constructor Summary
Constructors Constructor Description RoomServerAcl()
-
Method Summary
-
Methods inherited from class io.github.ma1uta.matrix.event.StateEvent
getPrevContent, getStateKey, setPrevContent, setStateKey
-
Methods inherited from class io.github.ma1uta.matrix.event.RoomEvent
getEventId, getOriginServerTs, getRoomId, getSender, getUnsigned, setEventId, setOriginServerTs, setRoomId, setSender, setUnsigned
-
Methods inherited from class io.github.ma1uta.matrix.event.Event
getContent, setContent
-
-
-
-
Field Detail
-
TYPE
public static final String TYPE
An event to indicate which servers are permitted to participate in the room. Server ACLs may allow or deny groups of hosts. All servers participating in the room, including those that are denied, are expected to uphold the server ACL. Servers that do not uphold the ACLs MUST be added to the denied hosts list in order for the ACLs to remain effective.
The allow and deny lists are lists of globs supporting ? and * as wildcards. When comparing against the server ACLs, the suspect server's port number must not be considered. Therefore evil.com, evil.com:8448, and evil.com:1234 would all match rules that apply to evil.com, for example.
The ACLs are applied to servers when they make requests, and are applied in the following order:- If there is no m.room.server_acl event in the room state, allow.
- If the server name is an IP address (v4 or v6) literal, and allow_ip_literals is present and false, deny.
- If the server name matches an entry in the deny list, deny.
- If the server name matches an entry in the allow list, allow.
- Otherwise, deny.
- See Also:
- Constant Field Values
-
-
Method Detail
-
getType
public String getType()
Description copied from class:Event
Required. The type of event. This SHOULD be namespaced similar to Java package naming conventions e.g. 'com.example.subdomain.event.type'.- Specified by:
getType
in classEvent<RoomServerAclContent>
- Returns:
- The type of the event.
-
-