PROTOCOL NOTES / 12
02 · Invitation import, discovery and first connection
Participants: Invitation, Engine, Aware, Peer
Implemented software · Physical qualification pending
Starting state
Joiner idle; receives QR or clipboard invitation through native UI. Organizer admission remains open.
Ordered events
- Invitation → Engine
Native scan/paste passes invitation directly
- Engine → Engine
Validate version, organizer key hash, ride ID and token lengths
- Engine → Aware
Subscribe to the fixed service; the ride tag of the signed advertisement selects this ride
- Aware → Engine
discovered callback supplies opaque handle and signed advertisement
- Engine → Aware
Select desired peer handle for an initiator request
Fields and messages
Invitation prefix rideweave:v2: and v=3; discovered peerHandle/advertisement; desiredParent differs from activeParent.
Authorization and invariants
Invitation is out-of-band trust. Open the sealed discovery information with the ride-token key, then verify advertisement version 3, signature/tag and monotonic serial; advertisements of other rides on the shared service fail authentication and are discarded; discovery does not grant membership or media authority.
Timers
Discovery fresh 6 s; root pulse fresh 4.5 s; request establishment budget 25 s.
Resource lifetime
Imported ride data lives until leave. Peer handles belong to the current discovery session and may change.
What the rider sees
Joining progress identifies discovery/connection/approval stages; secrets never enter React Native snapshot.
Failure branches
an invitation with another version is rejected; invalid import preserves prior state; stale/cyclic advertisements are ignored.
Resulting state
Joiner is joining; validated invitation trust and a discovered desired peer are retained.
Evidence boundary
Host invitation/discovery tests; instrumentation invitation tests compile, execution limited by current emulator environment.
Authority: RWCP v2 reviewed scenario catalogue, scenario 02. Public examples are synthetic. This guide is maintained against the private implementation; it does not imply access to its source.