aboutsummaryrefslogtreecommitdiffstats
path: root/WireGuard/WireGuard/UI/iOS/ViewController/TunnelDetailTableViewController.swift
diff options
context:
space:
mode:
authorJason A. Donenfeld <Jason@zx2c4.com>2019-02-06 03:23:51 +0100
committerJason A. Donenfeld <Jason@zx2c4.com>2019-02-06 06:20:23 +0100
commitbebcaa012bfafb5ab1a8ee4db11feffd3843c52c (patch)
treeee89b91f60bd267c356b0931d72bde9a288c8771 /WireGuard/WireGuard/UI/iOS/ViewController/TunnelDetailTableViewController.swift
parentLegacyConfig: Remove and support plaintext for .mobileconfig (diff)
downloadwireguard-apple-bebcaa012bfafb5ab1a8ee4db11feffd3843c52c.tar.xz
wireguard-apple-bebcaa012bfafb5ab1a8ee4db11feffd3843c52c.zip
PrivateDataConfirmation: prompt with touch/face/pin/password ID for viewing/exporting keys
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
Diffstat (limited to 'WireGuard/WireGuard/UI/iOS/ViewController/TunnelDetailTableViewController.swift')
-rw-r--r--WireGuard/WireGuard/UI/iOS/ViewController/TunnelDetailTableViewController.swift13
1 files changed, 8 insertions, 5 deletions
diff --git a/WireGuard/WireGuard/UI/iOS/ViewController/TunnelDetailTableViewController.swift b/WireGuard/WireGuard/UI/iOS/ViewController/TunnelDetailTableViewController.swift
index 955bf91..f65ca23 100644
--- a/WireGuard/WireGuard/UI/iOS/ViewController/TunnelDetailTableViewController.swift
+++ b/WireGuard/WireGuard/UI/iOS/ViewController/TunnelDetailTableViewController.swift
@@ -103,11 +103,14 @@ class TunnelDetailTableViewController: UITableViewController {
}
@objc func editTapped() {
- let editVC = TunnelEditTableViewController(tunnelsManager: tunnelsManager, tunnel: tunnel)
- editVC.delegate = self
- let editNC = UINavigationController(rootViewController: editVC)
- editNC.modalPresentationStyle = .formSheet
- present(editNC, animated: true)
+ PrivateDataConfirmation.confirmAccess(to: tr("iosViewPrivateData")) { [weak self] in
+ guard let self = self else { return }
+ let editVC = TunnelEditTableViewController(tunnelsManager: self.tunnelsManager, tunnel: self.tunnel)
+ editVC.delegate = self
+ let editNC = UINavigationController(rootViewController: editVC)
+ editNC.modalPresentationStyle = .formSheet
+ self.present(editNC, animated: true)
+ }
}
func showConfirmationAlert(message: String, buttonTitle: String, from sourceView: UIView, onConfirmed: @escaping (() -> Void)) {