I think such a protocol is not possible.
Let's say you have a connection
arbiter /\ / \ / \ / \ / \ peerA --- peerB
And now one of the peers disconnected peerA - peerB.
Before disconnecting, the whole situation may arise. (Sending data to B or B, or B-> A, or something else.)
Since there is no A ↔ B link, you cannot tell who is breaking the connection. Both parties may declare that
a) they send the last packet
b) they did not receive the package
The point is that when the link A ↔ B has disappeared, you cannot determine who violates it, because it can even be a third party in the middle.
One practical solution, in my opinion, is that as soon as this happens, you redirect all traffic from the arbiter, which now acts as a proxy. Both sides, meanwhile, direct the track to each other and send the results to the arbiter. Even if this does not succeed and scammers implement fake ICMP packets, this method of cheating will not work, and sooner or later they will refuse this method of cheating. In the worst case scenario, you will have to redirect some traffic and act like a router, but you can statistically track cheaters and take the right action against them.
source share