PROTOCOL NOTES / 04

Android transport

Keep requests, interfaces, endpoints, and peers separate.

Implemented software · Physical qualification pending

A peer is not a network interface

Android may share one Wi-Fi Aware network interface across multiple data paths. Treating the interface as though it belonged to one peer can tear down unrelated links. RWCP separates request ownership, installed bindings, local endpoints, and authenticated peer connections.

Shared interface ownership: releasing one peer must preserve the other peer’s resources.
Shared interface ownership: releasing one peer must preserve the other peer’s resources. · Open full size ↗
ResourceLifetime and identity
Aware requestRequest ID and session generation; can fail or retire independently
Network bindingAndroid Network/interface scope and incarnation; reference-counted use
Local endpointListener/UDP resources on an installed binding
Peer connectionRemote scoped IPv6 address, negotiated media port and authenticated identity

Install first, acknowledge, then use

An asynchronous Android callback is not proof that a usable native path exists. Native installation acknowledges the exact request, session, and binding incarnation. Stale callbacks cannot attach a previous path to a new session. Releasing a peer drops only its own references.

Bind sockets before connecting

Sockets bind to the relevant network before listen, connect, or send. IPv6 scope IDs distinguish link-local addresses. UDP delivery is keyed by binding, scoped remote address, and the peer’s negotiated port—not IP address alone. The initiator does not create an extra listener, and the process is not globally bound to one network.

Capacity is an admission and recovery constraint

Supported data paths, pending reservations, and installed requests are distinct counts. The adapter reserves room for upstream recovery instead of evicting children. A genuine no-spare-capacity condition can select break-before-make; a generic request failure must not destroy the still-working parent.

Authority: Android transport ownership. Public examples are synthetic. This guide is maintained against the private implementation; it does not imply access to its source.