aboutsummaryrefslogtreecommitdiffstats
path: root/WireGuard/WireGuardNetworkExtension/PacketTunnelProvider.swift
diff options
context:
space:
mode:
authorRoopesh Chander <roop@roopc.net>2018-12-19 16:26:28 +0530
committerRoopesh Chander <roop@roopc.net>2018-12-19 18:35:53 +0530
commit5c501ac9a61da1804f816ddcff812939c06c5c37 (patch)
tree060195496895a5d693b1c079982c153932ee4bf7 /WireGuard/WireGuardNetworkExtension/PacketTunnelProvider.swift
parentRemove non-helpful comments (diff)
downloadwireguard-apple-5c501ac9a61da1804f816ddcff812939c06c5c37.tar.xz
wireguard-apple-5c501ac9a61da1804f816ddcff812939c06c5c37.zip
NE: Log whether tunnel was activated from the app or not
Signed-off-by: Roopesh Chander <roop@roopc.net>
Diffstat (limited to '')
-rw-r--r--WireGuard/WireGuardNetworkExtension/PacketTunnelProvider.swift6
1 files changed, 6 insertions, 0 deletions
diff --git a/WireGuard/WireGuardNetworkExtension/PacketTunnelProvider.swift b/WireGuard/WireGuardNetworkExtension/PacketTunnelProvider.swift
index 814ed59e..f0ae3e7f 100644
--- a/WireGuard/WireGuardNetworkExtension/PacketTunnelProvider.swift
+++ b/WireGuard/WireGuardNetworkExtension/PacketTunnelProvider.swift
@@ -41,6 +41,12 @@ class PacketTunnelProvider: NEPacketTunnelProvider {
let tunnelName = tunnelConfiguration.interface.name
wg_log(.info, message: "Starting tunnel '\(tunnelName)'")
+ if activationAttemptId != nil {
+ wg_log(.info, staticMessage: "Tunnel activated from the app")
+ } else {
+ wg_log(.info, staticMessage: "Tunnel not activated from the app")
+ }
+
let isActivateOnDemandEnabled = tunnelProviderProtocol.isActivateOnDemandEnabled
if isActivateOnDemandEnabled {
wg_log(.info, staticMessage: "Tunnel has Activate On Demand enabled")