@@ -19,7 +19,17 @@ title: polyproto-chat
1919
2020[ Semantic versioning v2.0.0] ( https://semver.org/spec/v2.0.0.html ) is used to version this specification.
2121
22- ## 1. Federating direct/group messages
22+ ## 1. Federation
23+
24+ This chapter covers the main federation mechanisms used to transfer messages between networks.
25+
26+ <!-- > tldr:
27+ - send message to own server
28+ - notify other members about update
29+ - other members pull message from server
30+
31+ either that or we directly take advantage of encryption and do something more efficient that way. idk im tired i need sleepies
32+ <-->
2333
2434### 1.1 Direct messages
2535
@@ -58,22 +68,22 @@ requests are verified correctly by the server.
5868
5969``` mermaid
6070sequenceDiagram
61- participant Charlie
62- participant Server
63- participant Alice
64- participant Bob
65-
66- Charlie->>Server: Channel join request + KeyPackage
67- Server->>Alice: Notify group of join request
68- Alice ->>Server:
69- Server ->>Alice: Channel join request + Charlie's KeyPackage
70- Alice ->>Bob: Verify Charlie 's KeyPackage
71- Bob ->>Alice: Verified
72- Alice ->>Server : Notify group of new member: Charlie
73- Server ->>Alice : Encrypted MLS Welcome
74- Server ->>Bob : Forward: Notify group of new member: Charlie
75- Bob ->>Server : Forward: Notify group of new member: Charlie
76- Server ->>Charlie : Forward: encrypted MLS Welcome
71+ autonumber
72+
73+ participant c as Charlie
74+ participant s as Server
75+ participant a as Alice
76+ participant b as Bob
77+
78+ c ->>s: Channel join request + KeyPackage
79+ s ->>s: Notify group of join request
80+ s ->>a: Channel join request + c 's KeyPackage
81+ a ->>a: Verify c's KeyPackage
82+ a ->>s : Notify group of new member: c
83+ a ->>s : Encrypted MLS Welcome
84+ s ->>b : Forward: Notify group of new member: c
85+ s ->>c : Forward: Notify group of new member: c
86+ s ->>c : Forward: encrypted MLS Welcome
7787```
7888
7989Fig. 3: Sequence diagram of a successful encrypted channel join in which Alice acts as a gatekeeper.
@@ -89,6 +99,8 @@ Bob and Charlie.
8999
90100``` mermaid
91101sequenceDiagram
102+ autonumber
103+
92104participant Alice
93105participant Server
94106participant Bob
@@ -112,6 +124,8 @@ from the group. The Group owner is determined by the Client-Server API.
112124
113125``` mermaid
114126sequenceDiagram
127+ autonumber
128+
115129participant Alice as Alice (gatekeeper)
116130participant Server
117131participant Bob
0 commit comments