What Does a VPN Connection Failure Look Like?

Thirteen switches between VPN lines in one hour, and the questions client records can answer

Author: Nono VPN Technical report v0.2.8 Revised 24 November 2026 (UTC)

This is an English translation of the Chinese original. If the two differ, the Chinese original prevails.

Abstract A user reported that their VPN felt sluggish. We then developed a rule for scoring connection quality for each account in each UTC hour and applied it retrospectively to the preceding seven days of records. According to the September calibration record, our backend reconstructed 18 connection sessions from that account's client events for the hour the user described. The counting program recorded 13 switches between lines, the node-and-protocol options that users can choose in the app. In that retrospective check, the rule did not flag that hour. We reconstruct how the rule handled this case. Using synthetic events, we test how the switch count depends on recorded main-button taps and on when a switch occurs relative to the top of a UTC hour. The calibrated September version of the counting program and a later code snapshot agreed on all nine synthetic test cases in our table and on 120 combinations of boundary conditions. We also reviewed earlier verification records for the released iOS and macOS builds. When the macOS app (version 1.0.5, build 56) judges a connection degraded, it can reconnect automatically. If it does, the old session stops probing and records no recovery event for that degradation. The records explain why the rule missed the hour in which the user reported a slowdown, and they show which existing events are not enough to measure recovery time. We do not know how long this user actually waited, because we lack a continuous record of requests and responses from their device.

Download replication materialZIP with the Chinese original, the English translation, the script and the synthetic data · 26 KB
In this article

1 An hour that went unflagged

In September 2026, a Nono VPN user reported that the service was very sluggish in the evening. After receiving the report, we developed a rule for scoring connection quality by account and UTC hour, hereafter the old rule, and applied it to the preceding seven days of records. For the period in question, the backend reconstructed 18 sessions from client events and, under the rule, counted 13 switches between lines. A line is one of the node-and-protocol options that users can choose in the app. Some screens of the app's English interface call these options nodes. The old rule worked per account and per UTC hour, and treated each of the following kinds of behavior as one class of signal: failed connection attempts, connection degradation or automatic reconnects, getting stuck while connecting, short sessions ended by the user, and line switches. Only an hour that hit at least two classes of signal was flagged as having connection trouble. Under the old rule, line switches counted as a single class no matter how many there were, and this hour hit only that class. This explains the discrepancy between the user's report and the old rule's result for that hour.

Two details of this case cannot be recovered from the records. First, users can pick a different line in the app, and the app can also switch lines on its own. That hour has no records that would distinguish the two, switch by switch. Second, the client events do not show whether the device received responses when the user tried to load pages. Session reconstruction can show only that the line name changed. The 18 sessions, the 13 line switches, and the user's single report of sluggishness therefore describe three different things. From them we cannot count 13 network failures, nor determine whether the last switch solved the problem.

2 Data sources and methods

This report combines a retrospective case analysis with deterministic code replay. The historical material comes from two internal records: the calibration record for the quality rule, written on 8 September, and the verification record for the released builds, compiled on 19 November for our first report. We did not query the production database again for this analysis. The three sets of material use different units of observation.

Material Scope and unit of observation Purpose
Quality rule calibration record, September 18:00 on 1 September to 17:00 on 8 September 2026 (UTC, hours labeled by their start, first and last hours included, 168 hours in total). The unit is one account's activity within one UTC hour Confirm the known case, the calibration denominator, and the number of flagged hours before and after the rule change
Verification record for the released iOS and macOS builds iOS 1.0.30 (221), a seven-day window from 12 to 19 November. A thirty-day window from 20 October to 19 November, covering connection-health and automatic-reconnect events from macOS 1.0.5 (56), the previous version 1.0.4 (53), and all iOS versions. Both windows run from 00:00 UTC on the first day to 00:00 UTC on the last day, which is excluded, and events are assigned by the time the server received them. The unit is an event entry Check what each of these leaves in the records: a tap that does not lead directly to a connection attempt, connection degradation, automatic reconnects, and recovery
Offline code replay One synthetic account, one simulated device, and two nodes, observed over two adjacent UTC hours. We ran the counting program from the September calibrated commit and from a later code snapshot Change one input and observe whether the switch count and the hour flags change

The two code versions belong to the revision history of the same implementation. The replay tests whether these behaviors agree between the two versions. Other revisions between them were not replayed one by one.

The September calibration used a denominator of 2,070 active account-hours with telemetry. An account-hour qualified if it overlapped one of the account's reconstructed sessions and if, during that hour, the account had at least one eligible connection-related client event from any of its devices. There are nine such event types, including connection success and failure, disconnection, connection health, automatic reconnects, and main-button taps. At the time, iOS events of these types counted only if they came from a build released on the App Store. Android events were excluded. Events from macOS and the remaining platforms counted regardless of build. Clients with diagnostics turned off do not send connection events, so an account-hour in which none of the account's devices sent an eligible event is not in the denominator. Account-hours with server-side enforcement records, such as rate limiting, were left out of the denominator in both rounds. One account could contribute several hours. The September record does not say whether internal accounts were removed from this denominator.

The event counts in the build verification record do not exclude internal or test devices. Part of the seven-day window also predates the release of 1.0.30 (221), and part of the thirty-day window predates the release of 1.0.5 (56). We use these counts only to confirm that each kind of event and recording path exists, not to compute rates. For the client logic, we started from the existing build verification notes and rechecked the relevant lines against the source code of the two released builds. We did not re-verify them on physical devices. The code we actually retrieved and ran was the server-side counting code.

A network measurement has to state what its observer can see. From the two points of view of network characterization and application performance estimation, RFC 6703 discusses how long to wait before declaring a packet lost and how packets that never arrive should be treated in delay statistics [1]. VPNalyzer cut the communication between a test machine and a VPN server under controlled conditions and checked whether probe requests and DNS queries leaked outside the tunnel during the outage. It did not measure whether or when the VPN reconnected, or when requests began to succeed again [2]. This report addresses a question under more limited observation: when a client has only button, session, and probe events, which user experiences can still be identified? Later measurements of request recovery follow the M3 definition in Nono VPN's first report [3].

3 How the same switching behavior gets counted

Under the calibrated program, when the count of one class of signal within an account-hour reaches that class's threshold, the class counts as two. The threshold for line switches is four, so four qualifying switches are enough on their own to flag the hour. To identify a switch, the program compares the full line names of two consecutive sessions on the same device. Each session takes the line name recorded in its connection-success event. If, during the session, a diagnostic event from the same connection attempt records a line name, that name is used instead, and it also fills in a missing name. If both names are non-empty and differ, that counts as one switch, including a change of protocol on the same node. The previous session must end no more than ten minutes before the next one starts. Each switch is assigned to the UTC hour in which the new session starts, and only a session that overlaps that hour is taken as the previous session. A session that ends exactly at the start of the hour does not overlap it. Two kinds of switches are not counted. The first is a switch where the same device recorded a main-button tap, to connect or to disconnect, within the 60 seconds before the new session started, the 60th second included. The second is a switch whose new session started within 120 seconds, inclusive, after a degradation or automatic reconnect that the same account recorded in the same UTC hour, on any device. A button event proves only that the client recorded a tap. It does not prove what the tap was meant to do.

Offline experiment. We had one synthetic device alternate between nodes A and B every 180 seconds. Each new connection-success event also ended the previous session. The input contained no connection failures, degradations, or automatic reconnects. The experiment varied, in turn, the number of switches, the timing of taps relative to the new session, and the position of the whole sequence relative to the top of a UTC hour. In groups A and B, the first connection success falls at second 100 of the earlier hour, and every switch falls within the earlier hour. The two implementations produced identical output, item by item, for all nine inputs in the table. The synthetic input for A3 has 14 sessions and the September case has 18. The two have only the number of switches in common.

Group Input condition Switches in the input Counted in earlier hour/later hour Flagged hours
A1 Same hour, no taps 3 3/0 0
A2 Same hour, no taps 4 4/0 1
A3 Same hour, no taps 13 13/0 1
A4 As A3, with a tap recorded 1 second before each switch 13 0/0 0
B1 Same hour, with a tap recorded 60 seconds before each switch 4 0/0 0
B2 As B1, with the taps moved to 61 seconds before 4 4/0 1
C1 No taps, the fourth switch 1 second before the top of the hour 4 4/0 1
C2 All events of C1 shifted 1 second later 4 3/0 0
C3 All events of C1 shifted 2 seconds later 4 3/1 0

The counts and flags in the table come from the two calibrated implementations. Under the old rule, the same nine inputs give the same counts, but no hour is flagged in any of them, because the old rule counts any number of switches as a single class of signal.

A3 and A4 pass through exactly the same nodes. The only difference is whether tap records were left. B1 and B2 show that the boundary is at 60 seconds: a switch whose tap came 60 seconds before the new session is still excluded, while one whose tap came 61 seconds before is not. So for switches that meet the other conditions for being counted, such as those in A3, A4, B1, and B2, whether a switch is counted depends on whether the same device recorded a main-button tap within the 60 seconds before the new session started. "13 counted switches" therefore means only that no main-button tap was recorded within the 60 seconds before any of the 13 new sessions started. It does not show who triggered the switches. According to the source code of the released builds verified in November, neither picking a different line in the app nor an automatic switch by the app leaves such a tap. We did not check the client build that the September user was running.

C2 and C3 reveal two different top-of-the-hour effects. In C3, all four switches are counted. Three fall in the earlier hour and one in the later hour, so neither hour reaches four. In C2, the fourth switch falls exactly on the hour, and the previous session ends at that same instant. Under the assignment rule above, the previous session does not overlap the new hour, so the program has nothing to compare against, and only three switches are counted across the two hours. As the program is written, whenever the previous session ends at or before the top of the hour and the next one starts at or after it, the switch is counted in neither hour. For example, a previous session ending 5 seconds before the hour followed by a new one starting 5 seconds after it is missed in the same way. In this experiment the sessions are back to back, so this happens only when a switch falls exactly on the hour. When the app switches lines automatically, the old session ends first and the new one starts somewhat later, so a top of the hour that falls in this gap also causes a missed count. We did not re-examine the switch-by-switch timeline of the September hour, so we do not know whether it hit this boundary.

Back to the historical sample. In the September calibration record, the old rule flagged 166 of these 2,070 account-hours (8.02%) and the calibrated new rule flagged 177 (8.55%). Only one rule was added between the two rounds: when the count of one class of signal reaches that class's threshold, the class counts as two. This never reduces the number of classes an hour hits, so every hour flagged by the old rule remains flagged under the new one, and the difference of 11 account-hours consists entirely of new flags, or 0.53 percentage points. In the calibration record, the number of hours hitting no class was 1,585 in both rounds, and the number hitting one class fell from 319 to 308, consistent with 11 hours moving from one class to two or more. The case described at the start went from missed to flagged because its count of line switches reached the threshold. The program applies the rule to every account-hour, but the rates count only hours in the denominator. The calibration record does not state whether that hour is among the 2,070, so we cannot tell whether it is one of the 11 new flags. The rule applies to several kinds of repeated behavior, each with its own threshold. The calibration record also does not say which class of signal triggered each new flag, so we cannot tell how many of the 11 came from line switches. The rule was added during calibration precisely to catch misses like this case, and the sample has no independent per-hour failure labels. The difference therefore measures only a change in the flagging rate. It cannot estimate the rule's sensitivity or the probability that users experience a failure.

4 Where do failures begin, and where does recovery stop being recorded?

After a tap on Connect. During the seven-day iOS verification window, the main button left 598 "connect" tap events, and 643 connection-attempt events were recorded at the lower level. The two cannot be matched one to one. When a user taps "Continue" on the first-time VPN permission explainer, the client replays the main-button logic and records another tap. A tap also does not always lead directly to an attempt. In 92 cases, the client recorded a tap and then, instead of starting an attempt, logged an event giving the reason. Of these 92 events, 89 indicate that the first-time VPN permission explainer was shown first, 2 indicate that the system's prompt for the app's network access had not yet been answered, and 1 indicates that this network access had previously been denied. The last two have nothing to do with authorizing the VPN configuration. On the other hand, retries started by the app (including automatic reconnects after a connection is established) and entry points other than the main button can also start attempts, and taps and attempts share no common identifier. The difference of 45 is therefore only the net difference between two counts and cannot be taken as the number of automatic retries. All 92 occur before a connection attempt, so classifying them as node connection failures would confuse the stage at which the failure occurred.

After the connection is established. During the thirty-day macOS verification window, 1.0.5 (56) recorded 12 connection degradation events, 0 recovery events, and 11 records of automatic reconnects after degradation. "Degradation" here is the client's own judgment about the health of the connection. The summary records do not pair these three kinds of events one by one. The source code of the released build shows that the client sends at most one such reconnect record per degradation, and only after the same session has been judged degraded. If the degradation behind each reconnect is among these 12, then at least 11 of the 12 degradations were followed by an automatic reconnect record. This assumption has not been checked record by record. It would fail, for example, if the record of a degradation never reached the server while the record of its reconnect did. In the same thirty-day window, all iOS versions together recorded only 2 connection-health events, both degradations, and none from 1.0.28 onward, so this part discusses macOS only.

The build verification notes describe two subsequent paths. If the original session keeps probing, a single HTTP response that meets the probe's criteria can trigger a recovery event, which reports the time elapsed since the client judged the connection degraded. On the other path, the client rechecks two seconds after the degradation judgment. It starts an automatic reconnect only if several conditions all hold, among them that the connection is still degraded, the user has not acted, a local network check outside the tunnel passes, and the rate limit for automatic reconnects has not been reached. Once the reconnect runs, probing of the old session stops, and the new session does not go back and record a recovery event for the old one along this path. The two seconds are the recheck wait before reconnecting. The reconnect itself still has to tear down the old session and establish a new one. The existing records cannot show at which stage the user sent a request or when the user could read the content.

This makes "0 recoveries" consistent with several situations. Pages may have come back soon after the reconnect, with observation of the old session already over. Or pages may have remained unavailable after the reconnect, or the user may have disconnected, quit, or let the device sleep before the reconnect. In each of these cases, the old session can end with a degradation record. A degraded session that does not start a reconnect keeps probing and can still record a recovery event. The degradation, recovery, and reconnect code of the previous macOS version, 1.0.4 (53), is identical to that of 1.0.5 (56), and in the same window 1.0.4 (53) recorded 11 degradations and 2 recoveries. Both versions have too few records to compare. The existing probes also lack per-request markers and proof of the exit path, so a successful response cannot necessarily be attributed to the intended VPN path. The available material cannot estimate this version's request recovery rate, median recovery time, or 90th-percentile recovery time. As described above, once an automatic reconnect runs, that degradation leaves no further recovery event, so how long it took to recover after the reconnect cannot be known. If recovery times are computed from recovery events alone, the sample includes only degradations where no reconnect ran.

5 How to measure recovery after a network switch on a real device

A network switch gives the test a starting point that can be recorded precisely, but whether it interrupts requests still has to be detected. The cause of the slowdown in the September case is unknown, and this test does not reproduce that kind of problem. For the question "after an iPhone switches from Wi-Fi to cellular, when can it fetch a page again?", we follow M3: the primary measure is whether recovery occurs within 60 seconds of detecting an interruption. For rounds that recover, we also record the time from the first confirmed request failure to the first qualifying response from the test page. The two-second request cadence and the request deadline limit the precision of this time, so it only approximates how long a user actually waits. When the interface shows "Connected" again is recorded as a separate observation. Receiving the specified content shows that the request has recovered. Studying full page rendering or whether a user finishes reading would require a different end point. The protocol below has not yet produced results on real devices.

  1. Confirm the path works before switching. Fix in advance the number of repetitions per group and the reason for it, the test order, and the timing parameters. Hold the device, operating system, app build, protocol, routing mode, and network combination constant. On the same device, use our own endpoint to confirm that the test page returns the expected content through the specified VPN exit. Give every request its own marker and rule out caching, and use an independent control to confirm that the endpoint is healthy. This step is called the pre-check below. Use a single monotonic clock to timestamp the zero point defined in step 2, the moment the tester turns off Wi-Fi, changes in the interface state, outgoing requests, and incoming responses, and verify that the clock keeps advancing while the device sleeps.
  2. Detect an interruption after the switch. Take as time zero the moment the test tool observes that the Wi-Fi network is no longer available (the tool monitors Wi-Fi as a physical network, not the VPN tunnel, and the moment the tester turns off Wi-Fi is recorded separately). Send test requests at seconds 0, 2, 4, 6, and 8, each with a two-second limit. These first ten seconds are called the initial observation period. When a request reaches its deadline, first handle any response received exactly at the deadline, which counts as on time, and only then declare a timeout. Record a missing qualifying response at the deadline as a failed test request only after confirming that the packet was sent and that the path settings, the endpoint's health, and the observation conditions were all valid. One such failure during the initial observation period counts as a detected interruption. Each switch that passed the pre-check falls into one of three categories: interruption detected, initial observation complete with no interruption detected, or initial observation insufficient to decide. A switch whose zero-point event is not observed within a time limit fixed in advance, counted from the moment the tester turns off Wi-Fi, falls into the last category.
  3. Keep observing until recovery or for one full minute. From the first confirmed failure, continue at the same cadence for at most 60 more seconds, and keep recording across automatic reconnects. Send only requests whose two-second limit ends within these 60 seconds. If observation continues to the end, the last request goes out 2 seconds before it. A qualifying response received exactly at the end still counts as on time. The first valid response must come from a request sent at or after the confirmed failure, carry back the matching marker, and be confirmed to have come through the designated VPN exit. If the interface shows "Connected" throughout, record that fact as such. Rounds with no interruption detected during the initial observation period are not entered as recovery trials and produce no recovery time.
  4. Report counts and times together. For rounds with a detected interruption, give four counts: recovered on time, observed through the deadline without recovery, explicitly canceled, and unknown. Their sum is the denominator for the group. Classify using only records up to the deadline, in this order. A round that receives a qualifying response within the deadline and before any cancellation record counts as recovered on time. A round in which, after time zero, at or before the deadline, and before any qualifying response, the tool recorded the tester disconnecting the VPN, quitting the app, or making a network settings change not called for by the protocol counts as explicitly canceled. If a qualifying response and a cancellation record carry the same timestamp, use the order in which the tool logged them, and if that order cannot be determined, count the round as unknown. A round not yet classified counts as observed through the deadline without recovery if every scheduled request was sent, all four conditions in step 2 held, and no qualifying response arrived by the deadline. Everything else, including missing records partway through the observation, counts as unknown. Dividing the on-time recoveries by this denominator gives the share "confirmed to recover within one minute". Also report the unknowns divided by the same denominator. When the denominator is zero, record both shares as not computable. List the times of the recovered rounds separately, and state the two-second request cadence and the request deadline. Repeated trials on the same device or the same network may be correlated, so report the numbers of devices, network combinations, and trials separately.

6 Scope and conclusions

This case shows that client records can help locate an hour that the old rule missed and, together with the rule itself, explain concretely how the miss happened. For that one hour in September, we know that the user reported sluggishness and why the old rule did not flag it. The offline replay also shows that, for the same sequence of switches, recorded taps and hour boundaries can change how many switches count in each account-hour and which account-hours are flagged. The case comes from a report the user chose to send, and the hourly sample is limited by diagnostic coverage and inclusion criteria, so the results cannot be extrapolated to all users or to other VPNs.

Recovery time needs a different kind of evidence: whether the device can receive the expected content through the specified path before and after the same interruption, and when it first receives it again. Historical events lack this end point, so the actual waiting time in the September case remains unknown. Later tests on real devices can measure recovery for specified combinations of device and network, but they cannot reconstruct what that user experienced that day.

Data, code, and researcher statement

This study was conducted by Nono VPN, the developer of the product. The historical part cites only one case, aggregate figures, and the existing build verification records. The case is reported without account identifiers or similar details, and raw user events are not included in the accompanying material. The code part uses deterministic synthetic inputs.

The replication material consists of the Chinese original README.md and the files reproduce.py and cases.csv in the examples/ directory. All three files must come from the same version. From a directory where both README.md and examples/ are visible, using Python 3.9 or later with the standard library only (verified with Python 3.9.6, 3.12.1, and 3.14.7), run:

python3 -I -B examples/reproduce.py
python3 -I -B examples/reproduce.py --check-report README.md

The script independently implements a simplified formula based on the rules stated in the report. It applies only to the synthetic inputs constructed here: two alternating nodes, back-to-back sessions, and no other events. The first command computes each row of cases.csv (nine in this version) and compares it with the stored results. If all agree, it prints the header and the rows. If any row differs, it exits with an error. The second command also checks the table in Section 3 of the Chinese original against the computed results, row by row: the groups and their order, the numbers of switches, the counts for each of the two hours, and the number of flagged hours must all match. The input condition column is descriptive text and is not checked. When the check passes, the last line of output is:

Report table matches: 9 rows.

Neither command needs network access or user data. In the CSV, switches is the number of switches, first_start_s is the time of the first connection success in seconds from the start of the first UTC hour, tap_lead_s is how many seconds before each switch a tap is recorded (NA means none), and the remaining four columns give, for each of the two hours, the number of counted switches and whether the hour is flagged.

We also ran the same inputs through the original counting programs in the September calibrated version and a later code snapshot, and all nine rows of the table agreed item by item. Each original implementation was also checked on 120 boundary conditions: 1 to 8 switches, a tap lead of none, 1, 59, 60, or 61 seconds, and the last switch falling 1 second before, exactly on, or 1 second after the top of the hour. All results agreed with the simplified formula. Some of these 120 cases also appear among the nine rows of the table, so the two should not be added together as independent samples. The original counting programs are unpublished product code and are not released with this report. These synthetic conditions cannot be used to estimate how often real users encounter them.

The text of this report, including this translation, and cases.csv are released under CC BY 4.0, and reproduce.py under the MIT License.

AI assistants took part in revising the text, designing the synthetic experiment, writing and rerunning the programs, and compiling and rechecking, against the source code of the two released builds, the verification records on which Section 4 relies. The explanations of the iOS and macOS clients start from the existing build verification and were rechecked against the source code. For this report, we did not re-verify the client behavior or measure it on physical devices. Version 0.2.1 was given to ChatGPT as a second reader. Of the research material, it read only the report and the two files in examples/. It first calculated the nine rows of the Section 3 table by hand from the text, and then ran the two commands above under Python 3.12.14. The hand calculation, the program output, and the report agreed cell by cell. It also raised 12 comments on wording and definitions. We checked these, together with the comments from an internal review by an AI assistant, one by one against the sources before revising the text into version 0.2.2. Version 0.2.2 was given back to ChatGPT to re-read the changes and to check the English abstract and this translation. It reran the two commands with the same results and raised 8 comments on the Chinese changes and 26 on the English, which we checked one by one against the sources before revising the text into version 0.2.3. Version 0.2.3 was given back to ChatGPT to re-read the changes. It raised 6 comments and found our reasons sound for not following two of its earlier suggestions. We checked the comments one by one against the sources before revising the text into version 0.2.4. Version 0.2.4 was given back to ChatGPT to re-read the changes, and it found no problems. We then checked the September counting program to see whether the reported case had to be one of the new flags. The program applies the rule to hours outside the denominator as well, and the calibration record does not state whether that hour was in the denominator, so we made that statement conditional and revised the text into version 0.2.5. An AI assistant then rechecked all changes since version 0.2.1 against internal records, and we checked its comments one by one against the sources before revising the text into version 0.2.6. Version 0.2.6 was given back to ChatGPT to re-read the changes since version 0.2.4. It raised 4 comments, which we checked one by one against the sources before revising the text into version 0.2.7. Version 0.2.7 was given back to ChatGPT to re-read the changes. It found that all 4 comments had been addressed and pointed out that this statement did not give the reason for the version 0.2.5 change precisely enough. We revised the text accordingly into version 0.2.8, also clarifying a similar phrase in Section 3 of this translation. The changes in version 0.2.8 were not given back to the second reader. This English translation was prepared with an AI assistant from the Chinese original.

References

  1. Morton A, Ramachandran G, Maguluri G. Reporting IP Network Performance Metrics: Different Points of View. IETF RFC 6703, 2012. doi:10.17487/RFC6703. See especially Sections 4.1 and 5.1. RFC Editor
  2. Ramesh R, Evdokimov L, Xue D, Ensafi R. VPNalyzer: Systematic Investigation of the VPN Ecosystem. Network and Distributed System Security Symposium (NDSS), 2022. doi:10.14722/ndss.2022.24285. Paper
  3. Nono VPN. VPN 的连接成功率应该怎么算? (How should VPN connection success be measured?) v0.3.6. Zenodo, 2026. In Chinese with an English abstract. See Section 1 for the inclusion criteria, request deadline, and outcome categories of M3. Zenodo
Download replication materialZIP with the Chinese original, the English translation, the script and the synthetic data · 26 KB