Jason A. Donenfeld
56ad5f74e9
Also refresh status
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-12-22 07:07:53 +01:00
Jason A. Donenfeld
49bf55021f
Reassign tunnelProvider if it changes from outside the app
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-12-22 06:56:12 +01:00
Eric Kuck
0bec5b04b0
All models now Equatable
...
Signed-off-by: Eric Kuck <eric@bluelinelabs.com>
2018-12-21 22:57:17 -06:00
Jason A. Donenfeld
d36e7e27ff
Clean up trailing whitespace
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-12-22 05:30:35 +01:00
Eric Kuck
9098cd1161
Removing a tunnel from iOS's settings is now immediately reflected in app
...
Signed-off-by: Eric Kuck <eric@bluelinelabs.com>
2018-12-21 21:59:43 -06:00
Jason A. Donenfeld
8365adf435
Localize remaining strings in network extension
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-12-22 03:42:01 +01:00
Jason A. Donenfeld
f2000aa1da
Combine double log invocations
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-12-22 02:21:07 +01:00
Jason A. Donenfeld
4ed646973e
Move name from interface to tunnel
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-12-22 00:28:18 +01:00
Jason A. Donenfeld
9295895e3a
Fix paren typo
...
"I am very anti-paren." --Eric
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-12-21 23:45:20 +01:00
Jason A. Donenfeld
7b9d4cb9e3
Nuke trailing spaces
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-12-21 23:34:56 +01:00
Eric Kuck
1fecd8eb6c
providerConfiguration is now a WgQuickConfig
...
Signed-off-by: Eric Kuck <eric@bluelinelabs.com>
2018-12-21 16:32:08 -06:00
Jason A. Donenfeld
ec031b1f19
Get rid of superflous isActivateOnDemandEnabled key
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-12-21 18:50:32 +01:00
Eric Kuck
8553723e04
Updated NETunnelProvider save format
...
Signed-off-by: Eric Kuck <eric@bluelinelabs.com>
2018-12-21 16:42:16 +01:00
Eric Kuck
5618c465a2
Added a String->[String] helper
...
Signed-off-by: Eric Kuck <eric@bluelinelabs.com>
2018-12-20 10:46:26 -06:00
Roopesh Chander
bba6d2f919
TunnelsManager: If only Activate On Demand has changed, don't restart tunnel
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-12-19 18:35:53 +05:30
Roopesh Chander
fa51e3f1d1
NE: Handle bad domain names and Activate On Demand
...
This combination causes iOS to keep trying to bring up the tunnel,
leading to a lot of displayMessage() alerts.
In this fix, if we get a DNS resolution error in an Activate On Demand
enabled tunnel, we silently retry 9 times (with a 4-second delay before
each retry) and then show the displayMessage() alert.
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-12-19 15:38:00 +05:30
Roopesh Chander
4e516d6769
TunnelsManager: Handle waiting on a stale tunnel
...
If we have a stale tunnel on which we don't get status updates we rely
on a timer to update the status (see commit 34a7e5b
). Previously, if
the user tries to activate another tunnel, that resulted in both tunnels
waiting indefinitely. This commit fixes that.
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-12-19 12:48:10 +05:30
Roopesh Chander
2582ddd6f6
Error handling: Add info on the underlying system error to error alerts
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-12-17 19:04:17 +05:30
Eric Kuck
ed9b4c85ed
Got TunnelsManager back under the max file length by splitting out NEVPNStatus+CustomStringConvertible
...
Signed-off-by: Eric Kuck <eric@bluelinelabs.com>
2018-12-16 23:51:25 -06:00
Roopesh Chander
2a22c0f2d6
Provide mock tunnels for the Simulator
...
To help in generation of screenshots for the App Store
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-12-16 01:15:10 +05:30
Eric Kuck
7a24f18eb7
Most similar views now shared between ViewControllers
...
Signed-off-by: Eric Kuck <eric@bluelinelabs.com>
2018-12-14 17:15:22 -06:00
Roopesh Chander
c4263da231
Fix tunnel remaining in 'Activating' state
...
It uses to remain in 'Activating' state when we don't get a status
update notification, for example, when turning on the tunnel repeatedly
without Internet connectivity.
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-12-14 17:33:56 +05:30
Jason A. Donenfeld
73be704b01
Deduplicate functions
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-12-14 00:01:50 +01:00
Jason A. Donenfeld
74e983ea6f
Can't -> cannot
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-12-13 23:17:05 +01:00
Roopesh Chander
48552d2663
NE: Communicate last error to app through a shared file
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-12-14 02:24:53 +05:30
Roopesh Chander
501e412b84
TunnelsManager: startActivation() need not take a tunnelConfiguration
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-12-14 00:40:18 +05:30
Eric Kuck
05d750539b
Reorganized ViewControllers (split out UIViews and UITableViewCells into their own classes)
...
All swiftlint warnings except one fixed up
Signed-off-by: Eric Kuck <eric@bluelinelabs.com>
2018-12-13 12:58:50 -06:00
Roopesh Chander
b256acc372
TunnelsManager: Remove mentions of 'internal error'
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-12-13 23:53:17 +05:30
Roopesh Chander
7e093575a4
TunnelsManager: Ask to check Internet connectivity in error alert
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-12-13 23:49:42 +05:30
Roopesh Chander
f67e1d8fc4
TunnelsManager: Remove unused variable
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-12-13 23:44:13 +05:30
Roopesh Chander
33af8845b6
TunnelsManager: Remove assert
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-12-13 23:43:15 +05:30
Roopesh Chander
3bddab8a9e
TunnelsManager: Fix race between multiple startActivation() calls
...
After startActivate() is called on a waiting tunnel, user might turn
on a different tunnel before the waiting tunnel's status gets updated.
This fix prevents that from happening.
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-12-13 23:34:00 +05:30
Roopesh Chander
f9239dae75
TunnelsManager: Reintroduce waiting for another tunnel to deactivate
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-12-13 23:21:49 +05:30
Roopesh Chander
bf58159d99
TunnelsManager: Report activation errors through the activationDelegate
...
Don't report activation errors through completion handlers
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-12-13 18:56:07 +05:30
Roopesh Chander
ba1d0c05be
Logging: Use ringlogger for logging from the app
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-12-13 17:37:20 +05:30
Roopesh Chander
5ae9eec555
Avoid using 'VPN' in code where possible
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-12-13 12:20:10 +05:30
Roopesh Chander
6528a581de
mv WireGuard/WireGuard/VPN/ WireGuard/WireGuard/Tunnel/
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-12-13 12:14:21 +05:30