diff options
| author | Christophe Besson <cbesson@gmail.com> | 2026-09-04 03:03:47 +0200 |
|---|---|---|
| committer | Christophe Besson <cbesson@gmail.com> | 2026-09-04 03:03:47 +0200 |
| commit | dad2157ada303a45655d2919f62905369525636f (patch) | |
| tree | 083d08cd15e1258e4fbcca3c3c619debb2857022 /packaging/win/node-entry.py | |
| parent | 41282b997e016da0773276a935434dd03631e1f3 (diff) | |
| download | meshbay-dad2157ada303a45655d2919f62905369525636f.tar.gz | |
fix: tolerate clock skew when verifying JWTs (leeway 60s)
A client whose clock is a little fast could not connect at all: the MNP
handshake verified the hub-issued token with no leeway, so a token whose
`iat` was a few seconds ahead of the node's clock failed with "the token
is not yet valid (iat)". Seen against a freshly-resumed VM guest.
`meshbay_common.handshake.JWT_LEEWAY_SECONDS = 60` is the shared value;
applied to the handshake, the node's own hub-token decode, revocation-token
verification, and the hub's access-token decode. 60s absorbs NTP-level skew
without meaningfully widening the window on a stolen token (they already
carry a jti and an exp).
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Diffstat (limited to 'packaging/win/node-entry.py')
0 files changed, 0 insertions, 0 deletions