2017-02-15 20:19:39 +00:00
|
|
|
digraph {
|
|
|
|
|
|
|
|
/* could shave a RTT by committing to the nameplate early, before
|
|
|
|
finishing the rest of the code input. While the user is still
|
|
|
|
typing/completing the code, we claim the nameplate, open the mailbox,
|
|
|
|
and retrieve the peer's PAKE message. Then as soon as the user
|
|
|
|
finishes entering the code, we build our own PAKE message, send PAKE,
|
|
|
|
compute the key, send VERSION. Starting from the Return, this saves
|
|
|
|
two round trips. OTOH it adds consequences to hitting Tab. */
|
|
|
|
|
2017-02-22 21:45:18 +00:00
|
|
|
start [label="Boss\n(manager)" style="dotted"]
|
2017-02-16 01:46:28 +00:00
|
|
|
|
2017-02-22 01:56:32 +00:00
|
|
|
{rank=same; P0_code S0}
|
|
|
|
P0_code [shape="box" style="dashed"
|
2017-02-23 00:56:39 +00:00
|
|
|
label="input -> Code.input\n or allocate -> Code.allocate\n or set_code -> Code.set_code"]
|
2017-02-22 01:56:32 +00:00
|
|
|
P0_code -> S0
|
|
|
|
S0 [label="S0: empty"]
|
2017-02-16 01:46:28 +00:00
|
|
|
S0 -> P0_build [label="set_code"]
|
|
|
|
|
2017-02-25 02:30:00 +00:00
|
|
|
S0 -> P_close_error [label="rx_error"]
|
2017-02-26 11:57:58 +00:00
|
|
|
P_close_error [shape="box" label="T.close(errory)"]
|
2017-02-25 02:30:00 +00:00
|
|
|
P_close_error -> S_closing
|
2017-02-24 01:29:56 +00:00
|
|
|
S0 -> P_close_lonely [label="close"]
|
|
|
|
|
2017-02-26 11:57:58 +00:00
|
|
|
P0_build [shape="box" label="W.got_code\nN.set_nameplate\nK.got_code"]
|
2017-02-16 01:46:28 +00:00
|
|
|
P0_build -> S1
|
2017-02-22 01:56:32 +00:00
|
|
|
S1 [label="S1: lonely" color="orange"]
|
2017-02-16 01:46:28 +00:00
|
|
|
|
2017-02-22 01:56:32 +00:00
|
|
|
S1 -> S2 [label="happy"]
|
2017-02-16 01:46:28 +00:00
|
|
|
|
2017-02-25 02:30:00 +00:00
|
|
|
S1 -> P_close_error [label="rx_error"]
|
2017-02-22 01:56:32 +00:00
|
|
|
S1 -> P_close_scary [label="scared" color="red"]
|
|
|
|
S1 -> P_close_lonely [label="close"]
|
2017-02-26 11:57:58 +00:00
|
|
|
P_close_lonely [shape="box" label="T.close(lonely)"]
|
2017-02-22 01:56:32 +00:00
|
|
|
P_close_lonely -> S_closing
|
2017-02-16 01:46:28 +00:00
|
|
|
|
2017-02-26 11:57:58 +00:00
|
|
|
P_close_scary [shape="box" label="T.close(scary)" color="red"]
|
2017-02-22 01:56:32 +00:00
|
|
|
P_close_scary -> S_closing [color="red"]
|
2017-02-16 01:46:28 +00:00
|
|
|
|
2017-02-22 01:56:32 +00:00
|
|
|
S2 [label="S2: happy" color="green"]
|
|
|
|
S2 -> P2_close [label="close"]
|
2017-02-26 11:57:58 +00:00
|
|
|
P2_close [shape="box" label="T.close(happy)"]
|
2017-02-22 01:56:32 +00:00
|
|
|
P2_close -> S_closing
|
2017-02-16 01:46:28 +00:00
|
|
|
|
2017-03-04 10:36:19 +00:00
|
|
|
S2 -> P2_got_phase [label="got_phase"]
|
|
|
|
P2_got_phase [shape="box" label="W.received"]
|
|
|
|
P2_got_phase -> S2
|
|
|
|
|
|
|
|
S2 -> P2_got_version [label="got_version"]
|
|
|
|
P2_got_version [shape="box" label="W.got_version"]
|
|
|
|
P2_got_version -> S2
|
2017-02-16 01:46:28 +00:00
|
|
|
|
2017-02-25 02:30:00 +00:00
|
|
|
S2 -> P_close_error [label="rx_error"]
|
2017-02-22 19:26:11 +00:00
|
|
|
S2 -> P_close_scary [label="scared" color="red"]
|
|
|
|
|
2017-02-16 01:46:28 +00:00
|
|
|
S_closing [label="closing"]
|
2017-03-03 07:55:59 +00:00
|
|
|
S_closing -> P_closed [label="closed\nerror"]
|
2017-03-04 10:36:19 +00:00
|
|
|
S_closing -> S_closing [label="got_version\ngot_phase\nhappy\nscared\nclose"]
|
2017-02-16 01:46:28 +00:00
|
|
|
|
2017-02-25 02:30:00 +00:00
|
|
|
P_closed [shape="box" label="W.closed(reason)"]
|
2017-02-16 01:46:28 +00:00
|
|
|
P_closed -> S_closed
|
|
|
|
S_closed [label="closed"]
|
2017-02-22 01:56:32 +00:00
|
|
|
|
2017-03-03 07:55:59 +00:00
|
|
|
S0 -> P_closed [label="error"]
|
|
|
|
S1 -> P_closed [label="error"]
|
|
|
|
S2 -> P_closed [label="error"]
|
|
|
|
|
2017-02-22 01:56:32 +00:00
|
|
|
{rank=same; Other S_closed}
|
|
|
|
Other [shape="box" style="dashed"
|
2017-03-04 10:36:19 +00:00
|
|
|
label="rx_welcome -> process\nsend -> S.send\ngot_message -> got_version or got_phase\ngot_key -> W.got_key\ngot_verifier -> W.got_verifier\nallocate -> C.allocate\ninput -> C.input\nset_code -> C.set_code"
|
2017-02-22 01:56:32 +00:00
|
|
|
]
|
|
|
|
|
|
|
|
|
2017-02-15 20:19:39 +00:00
|
|
|
}
|