Skip to content
This repository was archived by the owner on Aug 15, 2025. It is now read-only.

Commit a95eaff

Browse files
committed
more formatting changes, start rework of section 1
1 parent 25a1d19 commit a95eaff

File tree

1 file changed

+31
-17
lines changed
  • docs/Protocol Specifications/P2 Extensions

1 file changed

+31
-17
lines changed

docs/Protocol Specifications/P2 Extensions/chat.md

Lines changed: 31 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -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
6070
sequenceDiagram
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

7989
Fig. 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
91101
sequenceDiagram
102+
autonumber
103+
92104
participant Alice
93105
participant Server
94106
participant Bob
@@ -112,6 +124,8 @@ from the group. The Group owner is determined by the Client-Server API.
112124

113125
```mermaid
114126
sequenceDiagram
127+
autonumber
128+
115129
participant Alice as Alice (gatekeeper)
116130
participant Server
117131
participant Bob

0 commit comments

Comments
 (0)