Files
netbird/client/internal
riccardom 5341ab0a7b [client] pqkem: commit the initiator PSK only after Finish succeeds
processAnswer advanced the exchange to stateAwaitingRekey before init.Finish
derived the PSK. A rekey firing in that window chained the next offer off an
exchange whose key was not yet committed, letting the responder commit PSK N+1
before this side committed PSK N; a lost next answer then left the two peers on
different PSKs.

Move to an intermediate stateFinishing while deriving (OnDataPathRekeyed chains
only on stateAwaitingRekey, so it will not chain mid-derive), and advance to
stateAwaitingRekey only after Finish succeeds and the exchange is still current.

Found in cubic review on #7098 (client/internal/pqkem/convergence.go:194).
2026-10-07 13:25:03 +02:00
..
2026-09-11 14:48:54 +02:00