File tree Expand file tree Collapse file tree 1 file changed +20
-0
lines changed
Expand file tree Collapse file tree 1 file changed +20
-0
lines changed Original file line number Diff line number Diff line change @@ -293,3 +293,23 @@ sequenceDiagram
293293 end
294294 Note right of Backend: Saves: <br> - login-key <br> login-salt <br> - secret-salt <br> - encrypted secret
295295```
296+
297+ ### Add new user
298+ ``` mermaid
299+ sequenceDiagram
300+ Note left of Charger Frontend: User provides some kind of<br>authentication for new user
301+ Note over Charger Frontend: Generates new WireGuard keys
302+ Charger Frontend->>Charger: Sends authentication data and WireGuard keys
303+ Note over Charger: Read public key from authentication data and<br>encrypt WireGuard keys
304+ Charger->>Backend: Sends authentication data and<br>encrypted WireGuard keys
305+ Note over Backend: Authenticates request and stores keys
306+ alt auth successfull
307+ Backend->>Charger: Indicate success
308+ Note over Charger: Save WireGuard keys and user mail
309+ Charger->>Charger Frontend: Indicate success
310+ else auth failed
311+ Backend->>Charger: Indicate failure
312+ Note over Charger: Forget WireGuard keys and user data
313+ Charger->>Charger Frontend: Indicate failure
314+ end
315+ ```
You can’t perform that action at this time.
0 commit comments