aboutsummaryrefslogtreecommitdiffstats
path: root/WireGuard/WireGuard/UI/TunnelViewModel.swift (follow)
Commit message (Collapse)AuthorAgeFilesLines
* On-Demand: Add support for macOS-specific valuesRoopesh Chander2019-01-141-2/+13
| | | | Signed-off-by: Roopesh Chander <roop@roopc.net>
* import Foundation instead of UIKit wherever possibleRoopesh Chander2019-01-141-1/+1
| | | | Signed-off-by: Roopesh Chander <roop@roopc.net>
* Update copyrightJason A. Donenfeld2019-01-071-1/+1
| | | | Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
* Remove more commentsRoopesh Chander2018-12-231-21/+2
| | | | Signed-off-by: Roopesh Chander <roop@roopc.net>
* Attempt to strongly recommend thingsJason A. Donenfeld2018-12-221-4/+6
| | | | Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
* Move name from interface to tunnelJason A. Donenfeld2018-12-221-7/+12
| | | | Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
* Updated NETunnelProvider save formatEric Kuck2018-12-211-4/+4
| | | | Signed-off-by: Eric Kuck <eric@bluelinelabs.com>
* Localize all the thingsRoopesh Chander2018-12-211-36/+61
| | | | Signed-off-by: Roopesh Chander <roop@roopc.net>
* Enabled more swiftlint rulesEric Kuck2018-12-201-1/+1
| | | | Signed-off-by: Eric Kuck <eric@bluelinelabs.com>
* Added a String->[String] helperEric Kuck2018-12-201-22/+10
| | | | Signed-off-by: Eric Kuck <eric@bluelinelabs.com>
* Fix confusing indentationJason A. Donenfeld2018-12-151-3/+1
| | | | Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
* Reorganized project structureEric Kuck2018-12-141-0/+1
| | | | Signed-off-by: Eric Kuck <eric@bluelinelabs.com>
* Reorganized ViewControllers (split out UIViews and UITableViewCells into their own classes)Eric Kuck2018-12-131-0/+2
| | | | | | All swiftlint warnings except one fixed up Signed-off-by: Eric Kuck <eric@bluelinelabs.com>
* More formatting nits and cyclomatic complexity fixesEric Kuck2018-12-121-18/+16
| | | | Signed-off-by: Eric Kuck <eric@bluelinelabs.com>
* More linter warnings fixed, enabled more swiftlint rules, project cleanupEric Kuck2018-12-121-3/+3
| | | | Signed-off-by: Eric Kuck <eric@bluelinelabs.com>
* Tons more swiftlint warnings fixed. Still a few remaining.Eric Kuck2018-12-121-29/+27
| | | | Signed-off-by: Eric Kuck <eric@bluelinelabs.com>
* Added swiftlint and fixed all errors (and a bunch, but not all, warnings)Eric Kuck2018-12-121-11/+11
| | | | Signed-off-by: Eric Kuck <eric@bluelinelabs.com>
* Model: Declare keyLength constant and use that wherever applicableRoopesh Chander2018-12-091-4/+4
| | | | Signed-off-by: Roopesh Chander <roop@roopc.net>
* On-Demand: TunnelViewModel: Make activate-on-demand methods staticRoopesh Chander2018-12-081-2/+2
| | | | Signed-off-by: Roopesh Chander <roop@roopc.net>
* On-Demand: Move detail text to TunnelViewModelRoopesh Chander2018-12-081-0/+12
| | | | Signed-off-by: Roopesh Chander <roop@roopc.net>
* Make strings consistentJason A. Donenfeld2018-12-071-4/+4
| | | | Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
* It's 'WiFi', not 'Wifi'Roopesh Chander2018-11-281-5/+5
| | | | Signed-off-by: Roopesh Chander <roop@roopc.net>
* Tunnel view model: Invalidate the configuration object when updating allowedIPs using the 'Exclude private IPs' switchRoopesh Chander2018-11-191-0/+1
| | | | Signed-off-by: Roopesh Chander <roop@roopc.net>
* Tunnel view model: VPN-on-demand stuff shouldn't be part of the tunnel modelRoopesh Chander2018-11-121-16/+22
| | | | Signed-off-by: Roopesh Chander <roop@roopc.net>
* Tunnel edit, Tunnel view model: UI for providing On-Demand activation optionsRoopesh Chander2018-11-111-0/+16
| | | | Signed-off-by: Roopesh Chander <roop@roopc.net>
* Model: Ensure that a TunnelConfiguration always has a valid array of peersRoopesh Chander2018-11-101-2/+1
| | | | Signed-off-by: Roopesh Chander <roop@roopc.net>
* Tunnel view model: Peers in a configuation may not share the same public keyRoopesh Chander2018-11-061-0/+7
| | | | Signed-off-by: Roopesh Chander <roop@roopc.net>
* Tunnel view model: No need to save if we already have a validated configuration objectRoopesh Chander2018-11-051-0/+8
| | | | Signed-off-by: Roopesh Chander <roop@roopc.net>
* Global: run through swiftlintJason A. Donenfeld2018-11-031-2/+2
| | | | Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
* Ensure that all tunnel names are trimmed of whitespacesRoopesh Chander2018-11-031-1/+1
| | | | Signed-off-by: Roopesh Chander <roop@roopc.net>
* Tunnel view model: If there's just one peer, populate the scratchpad on initRoopesh Chander2018-11-021-7/+13
| | | | | | So that exclude private IPs can be computed correctly. Signed-off-by: Roopesh Chander <roop@roopc.net>
* Tunnel view model: Initialize peerData.numberOfPeersRoopesh Chander2018-11-021-0/+4
| | | | Signed-off-by: Roopesh Chander <roop@roopc.net>
* Global: fix up stringsJason A. Donenfeld2018-11-011-13/+13
| | | | Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
* UI: More elegant copy-to-clipboard behaviorJason A. Donenfeld2018-10-311-2/+1
| | | | Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
* Tunnel view model: IP address can be specified without '/cidr'Roopesh Chander2018-10-301-1/+1
| | | | Signed-off-by: Roopesh Chander <roop@roopc.net>
* Global: fix up captialization in headersJason A. Donenfeld2018-10-301-1/+1
| | | | Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
* Tunnel view model: Support for exclude private IPsRoopesh Chander2018-10-291-0/+70
| | | | Signed-off-by: Roopesh Chander <roop@roopc.net>
* Model: Allow creating an interface with empty nameRoopesh Chander2018-10-271-1/+1
| | | | | | | | 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>
* Model: MTU should be a 16-bit integerRoopesh Chander2018-10-271-2/+2
| | | | Signed-off-by: Roopesh Chander <roop@roopc.net>
* Tunnel detail: Don't show fields that have empty valueRoopesh Chander2018-10-271-0/+28
| | | | Signed-off-by: Roopesh Chander <roop@roopc.net>
* Tunnel creation: Compute public key from private key as the text is being editedRoopesh Chander2018-10-271-0/+12
| | | | Signed-off-by: Roopesh Chander <roop@roopc.net>
* Tunnel view model: Populate interface's public keyRoopesh Chander2018-10-271-0/+1
| | | | Signed-off-by: Roopesh Chander <roop@roopc.net>
* Smaller copyright headersRoopesh Chander2018-10-271-7/+2
| | | | Signed-off-by: Roopesh Chander <roop@roopc.net>
* Tunnel view model: Add copy public keyRoopesh Chander2018-10-271-0/+1
| | | | Signed-off-by: Roopesh Chander <roop@roopc.net>
* Tunnel view model: The view model applies for both editing and viewingRoopesh Chander2018-10-271-8/+8
| | | | Signed-off-by: Roopesh Chander <roop@roopc.net>
* Model: Use DNSServer in the Configuration modelRoopesh Chander2018-10-271-4/+13
| | | | Signed-off-by: Roopesh Chander <roop@roopc.net>
* Model: listenPort and persistentKeepAlive should be 16-bit integersRoopesh Chander2018-10-271-4/+4
| | | | Signed-off-by: Roopesh Chander <roop@roopc.net>
* Tunnel creation: Refactor by creating a separate view modelRoopesh Chander2018-10-271-0/+309
Signed-off-by: Roopesh Chander <roop@roopc.net>