fix timeout issue (maybe?)

This commit is contained in:
Schluffe committed 2026-10-16 12:01:43 +02:00
1 parent 95e4a879b9
commit b7f47531b7
7 files changed
+397 -5

No files matched your search

+25 -1
View File
@@ -12,7 +12,8 @@ explicit opt-in by both people; no relay is configured automatically.
1. The sender picks one file and configures STUN (PageQuit by default, Google,
Cloudflare, a custom provider, or None). They create a code and send it
privately to the intended receiver through an authenticated channel.
privately to the intended receiver through an authenticated channel. Normal
messenger copy/paste is supported; there is no need to transcribe codes.
2. The receiver pastes the code, creates an answer, and sends it back. The sender
pastes the answer. Gathering waits for completion, up to 30 seconds; a timeout
fails rather than quietly exporting incomplete connection information.
@@ -34,6 +35,8 @@ explicit opt-in by both people; no relay is configured automatically.
Cancel, reset, changing the selected file, or switching Send/Receive closes the
connection and aborts unfinished disk writes. Keep the tab open until receipt is
confirmed. A completed memory download is discarded when you reset or switch.
Switching browser tabs or apps to copy/paste does not explicitly cancel the
session, although a browser or mobile OS can suspend a background page.
Pending verification/acceptance expires after five minutes; stalled transfers
expire after one minute. The two peers must use this protocol version (v2);
legacy connection codes are rejected.
@@ -47,6 +50,27 @@ separate browser tabs or windows; switching Send/Receive inside one page cancels
that page's previous connection. Use the specific error shown in red to diagnose
failures; if a configured STUN server is unreachable, try None for a local test.
### Connection diagnostics and first-version comparison
Expand **Connection diagnostics** to copy the last 80 timed events. The log
retains local/remote candidate type counts, candidate-pair states, selected
route types, and ICE check request/response counters after failure. Final stats
are requested before closing the peer, with a 300 ms cleanup bound. A `?` means
the browser did not supply a counter; it does not mean zero. Addresses, raw SDP,
candidate IDs, credentials, server URLs and filenames are excluded.
Same-machine success does not establish cross-device connectivity. Error 701
alone does not establish the cause of a failed connection. A receiver shutdown
after both sides report completion can be normal sender cleanup.
The comparison with the first commit and controlled test results are recorded in
[the investigation notes](docs/connection-investigation.md). Run the isolated
ICE experiment with `node scripts/compare-ice.mjs firefox` or replace `firefox`
with `chromium`. This uses local browser peers and deliberately unusable offer
ports plus a 20-second answer delay; it is **not a cross-device test**. Add
`--normal-candidates` to preserve the real candidate ports. No firewall changes,
TURN credentials or public STUN service are required.
## Network privacy and optional TURN
STUN discovers externally reachable addresses. Its operator can see your public