summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorBug Magnet <marco.nikic@mullvad.net>2024-06-13 13:20:21 +0200
committerBug Magnet <marco.nikic@mullvad.net>2024-06-17 13:22:25 +0200
commit9030a3b015eb488f6babf7b5be2af1e7ce4b9e23 (patch)
treea9b5d5ea5133932b1ca4fe279814eaecc2416751
parentfc016433b51103badb74d1743c6ec61175b4aaef (diff)
downloadmullvadvpn-9030a3b015eb488f6babf7b5be2af1e7ce4b9e23.tar.xz
mullvadvpn-9030a3b015eb488f6babf7b5be2af1e7ce4b9e23.zip
Use a more appropriate protocol name
-rw-r--r--ios/MullvadPostQuantum/PostQuantumKeyNegotiator.swift4
-rw-r--r--ios/MullvadPostQuantumTests/MullvadPostQuantum+Stubs.swift4
-rw-r--r--ios/PacketTunnel/PostQuantumKeyExchangeActor.swift6
3 files changed, 7 insertions, 7 deletions
diff --git a/ios/MullvadPostQuantum/PostQuantumKeyNegotiator.swift b/ios/MullvadPostQuantum/PostQuantumKeyNegotiator.swift
index 4765ba7680..6876686fd0 100644
--- a/ios/MullvadPostQuantum/PostQuantumKeyNegotiator.swift
+++ b/ios/MullvadPostQuantum/PostQuantumKeyNegotiator.swift
@@ -14,7 +14,7 @@ import TalpidTunnelConfigClientProxy
import WireGuardKitTypes
// swiftlint:disable function_parameter_count
-public protocol PostQuantumKeyNegotiation {
+public protocol PostQuantumKeyNegotiating {
func startNegotiation(
gatewayIP: IPv4Address,
devicePublicKey: PublicKey,
@@ -32,7 +32,7 @@ public protocol PostQuantumKeyNegotiation {
/**
Attempt to start the asynchronous process of key negotiation. Returns true if successfully started, false if failed.
*/
-public class PostQuantumKeyNegotiator: PostQuantumKeyNegotiation {
+public class PostQuantumKeyNegotiator: PostQuantumKeyNegotiating {
required public init() {}
var cancelToken: PostQuantumCancelToken?
diff --git a/ios/MullvadPostQuantumTests/MullvadPostQuantum+Stubs.swift b/ios/MullvadPostQuantumTests/MullvadPostQuantum+Stubs.swift
index 8d4e2f30e3..1df6584444 100644
--- a/ios/MullvadPostQuantumTests/MullvadPostQuantum+Stubs.swift
+++ b/ios/MullvadPostQuantumTests/MullvadPostQuantum+Stubs.swift
@@ -43,7 +43,7 @@ class TunnelProviderStub: TunnelProvider {
}
}
-class FailedNegotiatorStub: PostQuantumKeyNegotiation {
+class FailedNegotiatorStub: PostQuantumKeyNegotiating {
var onCancelKeyNegotiation: (() -> Void)?
required init() {
@@ -68,7 +68,7 @@ class FailedNegotiatorStub: PostQuantumKeyNegotiation {
}
}
-class SuccessfulNegotiatorStub: PostQuantumKeyNegotiation {
+class SuccessfulNegotiatorStub: PostQuantumKeyNegotiating {
var onCancelKeyNegotiation: (() -> Void)?
required init() {
onCancelKeyNegotiation = nil
diff --git a/ios/PacketTunnel/PostQuantumKeyExchangeActor.swift b/ios/PacketTunnel/PostQuantumKeyExchangeActor.swift
index fef159af2c..a9a13e2635 100644
--- a/ios/PacketTunnel/PostQuantumKeyExchangeActor.swift
+++ b/ios/PacketTunnel/PostQuantumKeyExchangeActor.swift
@@ -15,7 +15,7 @@ import WireGuardKitTypes
public class PostQuantumKeyExchangeActor {
struct Negotiation {
- var negotiator: PostQuantumKeyNegotiation
+ var negotiator: PostQuantumKeyNegotiating
var inTunnelTCPConnection: NWTCPConnection
var tcpConnectionObserver: NSKeyValueObservation
@@ -30,7 +30,7 @@ public class PostQuantumKeyExchangeActor {
internal var negotiation: Negotiation?
private var timer: DispatchSourceTimer?
private var keyExchangeRetriesIterator: AnyIterator<Duration>
- private let negotiationProvider: PostQuantumKeyNegotiation.Type
+ private let negotiationProvider: PostQuantumKeyNegotiating.Type
// Callback in the event of the negotiation failing on startup
var onFailure: () -> Void
@@ -38,7 +38,7 @@ public class PostQuantumKeyExchangeActor {
public init(
packetTunnel: any TunnelProvider,
onFailure: @escaping (() -> Void),
- negotiationProvider: PostQuantumKeyNegotiation.Type = PostQuantumKeyNegotiator.self,
+ negotiationProvider: PostQuantumKeyNegotiating.Type = PostQuantumKeyNegotiator.self,
keyExchangeRetriesIterator: AnyIterator<Duration> = REST.RetryStrategy.postQuantumKeyExchange
.makeDelayIterator()
) {