Roopesh Chander
fc78187d54
mv Parsing/ ConfigFile/
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-29 19:05:01 +05:30
Roopesh Chander
ffc9b11efb
Settings: Add a settings panel
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-29 17:34:09 +05:30
Roopesh Chander
3791b2e1b9
Model: Cap networkPrefixLengths to valid values
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-29 16:49:49 +05:30
Roopesh Chander
1f8585443d
Tunnel edit: Support for exclude private IPs
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-29 16:44:47 +05:30
Roopesh Chander
12a87784dd
Tunnel view model: Support for exclude private IPs
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-29 16:43:53 +05:30
Roopesh Chander
c3c905884a
Tunnel edit: Fix keyboard type for reused cells
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-29 16:43:12 +05:30
Roopesh Chander
92c0f2a17e
Tunnel detail: Assume there's just one section per peer
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-29 13:02:11 +05:30
Roopesh Chander
81bbfcf46a
Tunnel edit: Assume there's just one section per peer
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-29 12:47:00 +05:30
Roopesh Chander
e4125f6d22
Tunnel edit: Set correct keyboard types
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-29 06:19:50 +05:30
Roopesh Chander
b7aaae7513
VPN: If we don't have to make a DNS request, we shouldn't enter that status
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-29 06:19:50 +05:30
Roopesh Chander
21ac338f64
VPN: Cache DNS resolutions while the app is in memory
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-29 06:19:50 +05:30
Roopesh Chander
e80e8b06c5
VPN: Reload the tunnel before starting it up
...
To avoid errors like this: https://stackoverflow.com/q/47550706
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-29 06:19:50 +05:30
Roopesh Chander
0baca8bf58
Tunnel list, detail: Deletion of tunnels
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-29 06:19:43 +05:30
Roopesh Chander
c955c5a913
VPN: Fix deletion of tunnels
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-29 04:54:57 +05:30
Roopesh Chander
7f77d87e27
Fix: Make sure all prepareForReuse() implementations call super
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-29 02:27:14 +05:30
Roopesh Chander
0396a3550c
Tunnel edit: Set correct title when editing
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-29 02:24:32 +05:30
Roopesh Chander
d48a4382b7
Tunnel detail: Change title after editing completes
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-29 02:21:19 +05:30
Roopesh Chander
335618a8db
Tunnel detail: Copying the public key
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-29 02:19:11 +05:30
Roopesh Chander
65d54d2e9f
Tunnel editing: Fix cell class names
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-29 02:15:43 +05:30
Roopesh Chander
95a451f4e1
Import: Use the refactored function for Open-in
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-29 02:09:50 +05:30
Roopesh Chander
dda43a0780
Import: Minor refactoring
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-29 02:08:40 +05:30
Roopesh Chander
b5ef62ddee
Import: Show errors when importing fails
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-29 02:03:39 +05:30
Roopesh Chander
3f97199f68
Import config: Directly add config, don't open up the editor
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-29 01:58:21 +05:30
Roopesh Chander
3356cfd688
Zip: Import configs from zip files
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-29 01:52:43 +05:30
Roopesh Chander
de3dde84fd
Zip: Add zip file reader
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-29 01:51:49 +05:30
Roopesh Chander
38b816ba4c
Zip: Include minizip in our Xcode project
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-29 01:03:53 +05:30
Roopesh Chander
718311b32c
Zip: Add code from the minizip project
...
Source: https://zlib.net/zlib-1.2.11.tar.gz
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-29 01:03:44 +05:30
Roopesh Chander
e9d90a2f0d
QR code: Save the scanned tunnel
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-28 23:32:15 +05:30
Jeroen Leenarts
f57953767b
QR code: Ask for title when scanning a QR code
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-10-28 23:20:18 +05:30
Roopesh Chander
981a745bcc
QR code: Minor refactoring
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-28 23:19:56 +05:30
Jeroen Leenarts
1335724c58
QR code: Support some form of rotation.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-10-28 23:19:52 +05:30
Jeroen Leenarts
09a2284104
QR code: Make sure correct layering is used to make sure hint remains visible.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-10-28 23:19:45 +05:30
Roopesh Chander
08c855fce6
QR code: Integrate Eric's QR code scanner
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-28 22:22:32 +05:30
Roopesh Chander
cd7baac0fc
Info.plist: Indicate that the app shall use the camera
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-28 22:01:02 +05:30
Roopesh Chander
fa410c668a
Tunnels list: Need to pass in a name to the parser
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-28 21:59:52 +05:30
Roopesh Chander
4855eafb39
Revert "Parser: Interface name can be added after parsing"
...
This reverts commit d3a9e79149
.
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-28 21:57:18 +05:30
Eric Kuck
3082863fd1
QR code: Ability to add tunnels with a QR code scan
...
Signed-off-by: Eric Kuck <eric@bluelinelabs.com>
2018-10-28 18:26:41 +05:30
Roopesh Chander
3d4409fc93
Model: Ensure name is not empty
...
We don't need it because we don't have to open the new-config UI
after scanning a QR code.
This reverts commit db72e95
.
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-28 18:13:47 +05:30
Roopesh Chander
a680fdf2bd
VPN: A tunnel may be already active on app startup
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-28 18:09:38 +05:30
Roopesh Chander
269a6c3719
VPN: Remove ability to deactivate the tunnel while resolving DNS
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-28 17:47:01 +05:30
Roopesh Chander
493166bd70
VPN: DNSResolver: Resolve multiple endpoints in parallel
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-28 17:44:25 +05:30
Roopesh Chander
dfbdcf3c28
Tunnels list: Add a switch and an activity indicator to the list view
...
They track the status of the tunnel. The switch can also be used to
bring the tunnel up and down.
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-28 14:56:15 +05:30
Roopesh Chander
1870a3d364
VPN: Save the tunnel name when modifying a tunnel
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-28 14:55:24 +05:30
Roopesh Chander
31e5d33114
Tunnel detail: For now, don't allow cancelling when resolving domains is in progress
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-28 14:54:41 +05:30
Roopesh Chander
78ab196a28
VPN: Cleaner derivation of subnet mask from CIDR network prefix length
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-28 11:51:18 +05:30
Roopesh Chander
011e1eeab8
Tunnel detail: The tableView should have selection disabled
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 19:14:08 +05:30
Roopesh Chander
a3e912a21f
VPN: Better error and status handling
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 19:07:16 +05:30
Roopesh Chander
dba3226a34
Xcode: Disable bitcode
...
Enabling bitcode generates a linker error when linking with libwg-go.a
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 19:07:16 +05:30
Roopesh Chander
793bf63989
VPN: Bring up the tunnel
...
The app figures out all settings and passes them in the
'options' parameter of startTunnel().
The network extension just takes them as is and just plugs the supplied
values into the right places.
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 19:07:16 +05:30
Roopesh Chander
a08e08fe2e
Xcode: Make Xcode build libwg-go.a automatically
...
This is based on Jeroen Leenarts' work (commit a3cdb84
)
and Jason Donenfeld's work (commit 9d01829
).
To reproduce:
In Xcode, add a new target called 'WireGuardGoBridge' with
the Cross-platform > External build system template. Configure
that target with the 'make' build tool and ask it to build on the
wireguard-go-bridge directory.
The Makefile in wireguard-go-bridge is already configured to
handle being called from Xcode as an external build system.
In WireGuardNetworkExtension's build phases, add a dependancy to
WireGuardGoBridge, and ask it to link to libwg-go.a (the make command
shall generate this archive). Add libwg-go.a as a library to be linked
with.
Edit the Xcode pbxproj file and in the file reference entry for
libwg-go.a, set path as "libwg-go.a" and sourceTree as
BUILT_PRODUCTS_DIR.
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 19:07:16 +05:30
Roopesh Chander
8d2bc4524a
VPN: Fix DNS resolution API
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 19:07:16 +05:30
Roopesh Chander
3044637196
NE: Add bridging header
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 19:07:16 +05:30
Roopesh Chander
11a6b988ce
NE: Remove entitlements we don't need for now
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 19:07:16 +05:30
Roopesh Chander
2c591f33c6
NE: Include the network extension in the project
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 19:07:16 +05:30
Roopesh Chander
e5840a1959
VPN: Perform DNS resolution before starting the tunnel
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 19:07:16 +05:30
Roopesh Chander
3aed009eb6
Tunnel detail: Account for status section in peer index calculations
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 19:07:16 +05:30
Roopesh Chander
3f4d12c404
VPN: DNSResolver: A class that does DNS resolution using getaddrinfo
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 19:07:16 +05:30
Roopesh Chander
10c4085239
Tunnel detail: UI for activating and deactivating a tunnel
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 19:07:16 +05:30
Roopesh Chander
a2daf09342
VPN: Activating, deactivating and tracking the status
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 19:07:16 +05:30
Roopesh Chander
f5e5c7f17d
Tunnel detail: Fix comment
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 19:07:16 +05:30
Roopesh Chander
0fcf48ce75
Model: Add a version number to the tunnel
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 19:07:01 +05:30
Roopesh Chander
c8fba951ad
VPN: Adding, modifying and deleting actual NETunnelProviderManager instances
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:02 +05:30
Roopesh Chander
ff7adb8bc8
Import: Support for importing a config file from file providers
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:02 +05:30
Roopesh Chander
f845d7557a
iPad: Fix modal presentation style
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:02 +05:30
Roopesh Chander
204cbc284a
iPad: Make sure the navigation bar is visible in the detail view
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:02 +05:30
Roopesh Chander
f7feb18ea8
Tunnel editing: Delegate should also report when editing is cancelled
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:02 +05:30
Roopesh Chander
05b9d6972b
Import: Support for opening a .conf file in the app
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:02 +05:30
Roopesh Chander
112b5c3b10
Tunnel editing: Separate init for creation and modification
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:02 +05:30
Roopesh Chander
a8dbeeda6d
Parser: Interface name can be added after parsing
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:02 +05:30
Roopesh Chander
1187657497
Model: Allow creating an interface with empty name
...
But don't allow such a tunnel to be added to the tunnel manager.
(We'll need to create an interface with an empty name when we're reading QR codes.)
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:02 +05:30
Roopesh Chander
1c8928c8a1
Info.plist: support for opening wg-quick config (.conf) files
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:02 +05:30
Roopesh Chander
6c33968fe3
Info.plist: Export the config file type declaration
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:02 +05:30
Roopesh Chander
e0c7006dbc
Config file: Parsing a wg-quick config file
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
7316eb06f8
Model: MTU should be a 16-bit integer
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
6cddb9e34b
VPN: Tunnel container shall provide direct access to the configuration object
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
06c84a22ca
Tunnel editing: Modifying a tunnel configuration
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
37f43759b8
Tunnel creation: After saving the new tunnel, show the detail view
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
0fad01107c
Tunnel detail: Don't show fields that have empty value
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
5b1876b998
Tunnel creation: Public key is uneditable
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
3b77f824b6
Tunnel creation: An uneditable field's value should be grey as well
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
0ae4b3bcf1
Tunnel creation: Generate key pair
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
571e9b5826
Tunnel creation: Compute public key from private key as the text is being edited
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
8f4875caf0
Tunnel view model: Populate interface's public key
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
b6d41ec9de
Model: Interface: Add a public key computed property
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
c689be7eff
Crypto: Swift wrapper for the Curve25519 C code
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Jeroen Leenarts
5bfb6a2c13
Crypto: Curve25519: Add explicit cast to supress conversion warning.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-10-27 15:13:01 +05:30
Roopesh Chander
acfa77f3df
Crypto: Add Curve25519 C code to project
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Jeroen Leenarts
834c9ae7ce
Crypto: Add key generation functions
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-10-27 15:13:01 +05:30
Roopesh Chander
7b915a8426
Tunnel creation: Hide 'Exclude private IPs' switch till the feature is ready
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
72ea54c0db
Set Xcode template for smaller copyright headers
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
8ebfc6afcd
Smaller copyright headers
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
c14d816b87
Tunnel detail: Start off with the tunnel detail view
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
88c7657eb7
Tunnel view model: Add copy public key
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
fa2760190b
Tunnel creation: Variable renaming
...
s/interfaceEditFieldsBySection/interfaceFieldsBySection/g;
s/peerEditFieldsBySection/peerFieldsBySection/g;
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
6243717a37
Tunnel view model: The view model applies for both editing and viewing
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
20b49518da
Tunnels list: Update when a tunnel is added
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
05efb453f3
Tunnel creation: Saving a configuration
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
722b3f6c7b
Model: Use DNSServer in the Configuration model
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
e1b8b67890
Model for DNS server
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
bcf8abb1de
Model: Endpoint host should not have invalid characters
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
b2f2756d9c
Model: listenPort and persistentKeepAlive should be 16-bit integers
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
607dd4bf3d
Tunnel creation: Refactor by creating a separate view model
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
b4554dce9b
Tunnel creation: Validate the data and prepare to save to a configuration
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
28293c8029
Tunnel creation: Save typed values in a scratchpad
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
1a534faa0a
Tunnel creation: Fix Persistent Keepalive label's look
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
911b16d54e
Tunnel creation: Start off with tunnel creation
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
2e96dbe363
Model: Make InterfaceConfiguration and PeerConfiguration structs
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
89214e7db9
Model: Make it impossible to create invalid interface / peer configuration instances
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
3331327d82
Use Endpoint in the Configuration model
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
c12f481b70
Model for an endpoint
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
8ec73025f2
Model: IPAddressRange: Converting to and from String
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
921b81e89b
Model: Name should be part of the interface, not the tunnel
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
6de354b4c5
Tunnels list: Show an actions list when the '+' is tapped
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
df7ea2a781
Tunnels list: Show data from the tunnels manager
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
8a11333b65
Tunnels list: Make the table view style explicit
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
b63abc65c3
VPN: Add TunnelsManager to manage the tunnels in the app
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
8ca3993804
Bump deployment target to iOS 12.0
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
ede2a82c3b
Use IPAddressRange in the Configuration model
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
0ce6b9e79e
Model for an IP Address range
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
3630543be5
Models for tunnel, interface and peer
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
78251e9a50
Configure the split-view controller to work in both iPhone and iPad
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
8d62cb3c1b
Change copyright to WireGuard LLC
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
5fe60a8bef
Use a split-view controller as the main (root) view controller
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
c76e5933e2
Move UI code into a separate platform-specific folder
...
Later, we hope to have a UI/macOS folder for developing a macOS client
from this codebase.
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
dd672d3dac
Prepare for rewrite: Move WireGuardNetworkExtension into the new project folder
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
5776523bd2
Use APP_ID in xcconfig rather than PRODUCT_BUNDLE_IDENTIFIER
...
This is required because when we add an app extension to the
project, there will be two PRODUCT_BUNDLE_IDENTIFIER fields
in our project file, so we cannot use xcconfig to set that
key directly.
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
6fe8b8dbe4
Enable Network Extensions capability
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
e2022d3e00
Move App ID to Developer.xcconfig as well
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
700c7221a9
Remove storyboard and create UI from code
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
b6f4806fd6
Move DEVELOPMENT_TEAM into an xcconfig out of the git repo
...
This is so that other developers can work on this codebase
by copying Developer.xcconfig.template to Developer.xcconfig
and setting the DEVELOPMENT_TEAM to their respective Team IDs.
The Team IDs need not be checked into source control.
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
6ada0a2857
Create a new project in Xcode
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Roopesh Chander
cc26734d5d
Prepare for rewrite: Remove UI and model code
...
Signed-off-by: Roopesh Chander <roop@roopc.net>
2018-10-27 15:13:01 +05:30
Jeroen Leenarts
6346bad069
Better handling of CIDR values.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-10-03 21:34:51 +02:00
Jeroen Leenarts
24f7dcb7d6
Disable auto corrects and related helpers on UITextfields.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-10-03 10:54:41 +02:00
Jeroen Leenarts
6cf4c49e21
Export qr scanned config to system settings.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-10-03 10:48:49 +02:00
Jason A. Donenfeld
c10532acd9
Remove extra comment cruft
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-10-03 01:21:59 +02:00
Jeroen Leenarts
12e33681c1
Remove a few prints, add some whitespace.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-10-02 22:36:39 +02:00
Jeroen Leenarts
bc279b1e79
Add some form of image for when no configurations are available.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-10-02 21:33:24 +02:00
Jeroen Leenarts
9906e6ba04
Dismiss qr scan vc on cancel.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-10-02 21:23:52 +02:00
Jeroen Leenarts
37be243317
Handle persistentKeepAlive better.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-10-02 21:19:27 +02:00
Jeroen Leenarts
c9a88ac29c
Add Wireguard logo to bottom of settings.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-10-02 21:14:47 +02:00
Jeroen Leenarts
eadb09eda8
Extract WireGuardGo version at build time.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-10-02 21:14:18 +02:00
Jeroen Leenarts
589bba60b1
Deal with type body length warning.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-10-02 19:53:56 +02:00
Jeroen Leenarts
7f6a7481c8
Copy public key through context menu.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-10-02 19:39:26 +02:00
Jason A. Donenfeld
cd86ba92ec
Rewrite bridge build system
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-10-02 19:15:03 +02:00
Jeroen Leenarts
33cdc14070
Don't crash on failure to obtain version info and inform user on what is needed to be able to retrieve version info from the Go client.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-10-01 15:37:15 +02:00
Jeroen Leenarts
86646448ac
Check and clear old configs on app start and app foreground.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-10-01 15:36:11 +02:00
Jeroen Leenarts
dd02986a78
Add switch to info view controller.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-09-29 22:29:34 +02:00
Jeroen Leenarts
ff1337d5ad
Deal with zero or empty input better.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-09-26 11:43:13 +02:00
Jeroen Leenarts
8e0a52a132
Use trash instead of edit icon.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-09-26 11:27:24 +02:00
Jeroen Leenarts
18d82d07af
Use message to extension to obtain version info.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-09-26 11:26:52 +02:00
Jeroen Leenarts
47a75bbd57
Fixe base 64 regex format.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-09-26 11:23:13 +02:00
Jeroen Leenarts
cc4bd254a2
Add explicit cast to supress conversion warning.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-09-26 11:22:15 +02:00
Jeroen Leenarts
a55eefcd5d
Fixe file/function related warnings.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-09-26 11:21:53 +02:00
Jeroen Leenarts
cd6c9a1203
Not a gear but dots.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-09-26 10:24:52 +02:00
Jeroen Leenarts
7042e36fb5
Present alert for title.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-09-25 22:30:16 +02:00
Jeroen Leenarts
df4e8e1fca
Remove default zeroes for listenPort and mtu.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-09-25 21:15:50 +02:00
Jeroen Leenarts
ad28815bef
Ask for title when scaning a QR.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-09-25 20:59:15 +02:00
Jeroen Leenarts
edaeaf732d
Move copy button a bit up towards title line.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-09-25 20:15:44 +02:00
Jeroen Leenarts
7aaa63d8e5
Settnings icon.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-09-25 20:10:29 +02:00
Jeroen Leenarts
19a4339a27
Report the correct number of rows in the info table view.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-09-20 00:44:24 +02:00
Jeroen Leenarts
659a24250a
Get rid of a few cosmetic lines.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-09-20 00:43:57 +02:00
Jeroen Leenarts
06f61cbc99
Make sure a scanned config is actually saved and displayed.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-09-20 00:43:43 +02:00
Jeroen Leenarts
7c608cc3be
Support some form of rotation.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-09-20 00:28:07 +02:00
Jeroen Leenarts
74ad02132a
Make sure correct layering is used to make sure hint remains visible.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-09-20 00:27:49 +02:00
Jeroen Leenarts
f993c3172e
Add add from file within app.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-09-19 16:02:20 +02:00
Jeroen Leenarts
c9974f9119
Add edit/done buttons to have a more discoverable way to remove tunnels.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-09-18 22:46:28 +02:00
Jeroen Leenarts
411c919cbf
Move add button to bottom toolbar.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-09-18 22:19:03 +02:00
Jeroen Leenarts
089315ddc5
Add settings screen. Move export as zip to settings screen.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-09-18 21:49:59 +02:00
Jeroen Leenarts
9d45f6e4b0
Spelling improvement in log statement.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-09-16 22:43:31 +02:00
Jeroen Leenarts
8326735fcb
Show public key on interface. Do not generate public key on peer on generate. Add public key copy buttons.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-09-16 22:38:32 +02:00
Jeroen Leenarts
c863adce85
Start a new peer without an allowed ips entry.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-09-16 21:23:20 +02:00
Jeroen Leenarts
d6e0838677
New peers should begin with zero peers.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-09-16 21:22:00 +02:00
Jeroen Leenarts
0af4dadd70
Back button for tunnel table view renamed to "Tunnels"
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-09-16 21:19:14 +02:00
Jeroen Leenarts
484bef1777
Clean up old school headers.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-09-16 21:17:54 +02:00
Jeroen Leenarts
878f6c54d1
We do not support "on demand" right now.
...
On demand has the effect of the VPN tunnel being started "on demand" based on a set of triggering criteria. Currently there are no criteria in place, so it always triggers.
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-09-15 21:26:07 +02:00
Jeroen Leenarts
6104546fc6
Add intermediate "Info" screen.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-09-15 21:24:52 +02:00
Jeroen Leenarts
3a8f8ef9e6
Prevent crash on add and deletion of config.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-09-15 21:23:47 +02:00
Jeroen Leenarts
b8abaa5283
Re-center app icon.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-09-15 20:29:28 +02:00
Jeroen Leenarts
3802a5c50b
Rename "WireGuard tunnels" to "WireGuard".
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-09-15 20:27:14 +02:00
Jeroen Leenarts
3dcaaa4e6c
Fix provisioning.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-09-15 20:26:17 +02:00
Jason A. Donenfeld
e379854dcb
Update bundle names
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-09-15 02:22:10 +02:00
Jeroen Leenarts
1379d97bbe
Switch copyright assignment from Jason to WireGuard LLC.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-09-06 07:42:23 +02:00
Jeroen Leenarts
d729a7686e
Working zip import.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-09-05 20:25:54 +02:00
Jeroen Leenarts
24623c4ea3
Remove item from provider managers on delete.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-09-05 20:25:32 +02:00
Jeroen Leenarts
b7755b97a3
Make sure to refresh provider managers after saving.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-09-05 20:10:09 +02:00
Jeroen Leenarts
56c543f1fc
Import of zip.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-09-03 00:08:34 +02:00
Jeroen Leenarts
8766750bb8
Zip export.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-09-02 22:47:41 +02:00
Jeroen Leenarts
2572c4781c
Add import and export logic.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-09-01 00:18:12 +02:00
Jeroen Leenarts
4950254013
Add addresses, dns and mtu to export string.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-08-31 21:40:24 +02:00
Jeroen Leenarts
b1aadaf82c
Add string conversion for tunnel config.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-08-29 15:01:59 +02:00
Jeroen Leenarts
2e9a12c63f
Initial merge of rc's work.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-08-27 22:32:47 +02:00
Jeroen Leenarts
56362ebd68
Move, modify and add key generation functions to project.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-08-27 13:38:50 +02:00
Eric Kuck
fc1ddc8b12
Reworked main tableview switch layout & logic
...
Signed-off-by: Eric Kuck <eric@bluelinelabs.com>
2018-08-22 13:34:08 -05:00
Jeroen Leenarts
e93e562f38
Use a Switch on each tunnel cell.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-08-21 22:27:44 +02:00
Jeroen Leenarts
dc1a3865af
Line selection configures the tunnel.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-08-21 20:04:14 +02:00
Eric Kuck
39ae9db11c
Added ability to add tunnels with a QR code scan. Logic in place to parse conf files as well.
...
Signed-off-by: Eric Kuck <eric@bluelinelabs.com>
2018-08-21 11:00:41 -05:00
Jeroen Leenarts
5a7e67b53c
Extend validators to work for DNS entries as well.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-08-16 22:41:45 +02:00
Jeroen Leenarts
bf3510765a
Use `commaSeparatedToArray` utility everywhere.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-08-16 22:39:08 +02:00
Jeroen Leenarts
603953a8b8
If the selected tunnel is not "enabled", make it enabled.
...
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2018-08-16 22:05:22 +02:00