Another language
The protocol is fully described in the ADARAZ Link specification. In short:
- Transport: WebSocket at
/api/adaraz/ws, subprotocoladaraz.v1, binary messages only, one WebSocket message = one Noise message (up to 4096 bytes). - Pairing:
Noise_XXpsk3_25519_AESGCM_SHA256, the PSK derived from the 12-character code (HKDF-SHA256). The server stores the reader's public key, the reader stores the server's. - Session:
Noise_IK_25519_AESGCM_SHA256. The reader sendshello, the server answerswelcomewith the cursor the reader sends punches from. - Punches:
punchesmessages (up to 100 items[index, uid_hex, unix_ts]), the server answersackonly after storing them durably. - Relay:
relay->relay_result, only with the reader administrator's consent.
To test your implementation, use the simulated reader from the adaraz library (Testing without a reader): an independent, tested implementation of the reader side.