Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 5 additions & 3 deletions auth.proto
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,12 @@ message Auth {

// Minutes since the project epoch (2024-01-01 UTC), used as a
// replay-prevention nonce. The Node accepts the message only if
// this value is within one minute of its own clock.
uint32 timestamp = 2;
// this value is within one minute of its own clock. Unit is
// encoded in the field name to distinguish from ms/Unix-epoch
// timestamps elsewhere in the protocol.
uint32 timestamp_min = 2;

// Truncated HMAC-SHA256 (12 bytes) over (client_id || timestamp),
// Truncated HMAC-SHA256 (12 bytes) over (client_id || timestamp_min),
// computed with the pre-shared key issued to this client. Proves
// possession of the PSK without revealing it.
bytes hmac = 3;
Expand Down
4 changes: 2 additions & 2 deletions ping.proto
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,9 @@ package proto;
message Ping {
// Client clock at the moment the Ping was prepared, in
// milliseconds since the Unix epoch. The Node echoes it back in
// Pong.timestamp so that the client can compute round-trip time
// Pong.timestamp_ms so that the client can compute round-trip time
// without keeping per-request state.
uint64 timestamp = 1;
uint64 timestamp_ms = 1;

// Per-peer probe-failure counters accumulated since the previous
// Ping. The key is the peer Node's IPv4 address in dotted form
Expand Down
4 changes: 2 additions & 2 deletions pong.proto
Original file line number Diff line number Diff line change
Expand Up @@ -95,8 +95,8 @@ message Peer {
// properties, fleet) so the client UI can stay current without a
// separate channel.
message Pong {
// Echo of Ping.timestamp, used by the client to compute RTT.
uint64 timestamp = 1;
// Echo of Ping.timestamp_ms, used by the client to compute RTT.
uint64 timestamp_ms = 1;

// Current lease snapshot for this client. Always present; an
// empty Lease means free tier.
Expand Down