-
Notifications
You must be signed in to change notification settings - Fork 37
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Make connection tester non-failable on VPN startup #1197
Make connection tester non-failable on VPN startup #1197
Conversation
@@ -821,7 +791,7 @@ open class PacketTunnelProvider: NEPacketTunnelProvider { | |||
} | |||
#endif | |||
} catch { | |||
self.cancelTunnelWithError(error) | |||
Logger.networkProtection.log("Connection Tester failed to start... will run without it: \(error, privacy: .public)") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is the most important change.
do { | ||
try await rekey() | ||
Logger.networkProtectionKeyManagement.log("Rekeying completed.") | ||
} catch { | ||
Logger.networkProtectionKeyManagement.error("Rekeying failed with error: \(error, privacy: .public).") | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we surface any errors outside of the tester so that the caller can fire a pixel or take some other action?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a good observation.
I've thought about this but it's unclear to me right now that this is needed, considering rekey failures are already recorded in the rekey()
call. Open to discussing more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Worked as expected in my tests, thanks!
Task/Issue URL: https://app.asana.com/0/1207603085593419/1209248230850409/f iOS PR: duckduckgo/iOS#3885 BSK PR: duckduckgo/BrowserServicesKit#1197 ## Description Make sure the Connection Tester isn't being used for rekeying anymore, so we can let it fail silently and not block VPN startup.
Task/Issue URL: https://app.asana.com/0/1207603085593419/1209248230850409/f macOS PR: duckduckgo/macos-browser#3791 BSK PR: duckduckgo/BrowserServicesKit#1197 ## Description Make sure the Connection Tester isn't being used for rekeying anymore, so we can let it fail silently and not block VPN startup.
Task/Issue URL: https://app.asana.com/0/1207603085593419/1209248230850409/f
iOS PR: duckduckgo/iOS#3885
macOS PR: duckduckgo/macos-browser#3791
What kind of version bump will this require?: Patch
Description
Make sure the Connection Tester isn't being used for rekeying anymore, so we can let it fail silently and not block VPN startup.
Steps to test this PR:
Please refer to the platform-specific PRs.
Internal references:
Software Engineering Expectations
Technical Design Template