Skip to content

Commit

Permalink
Fix small lints
Browse files Browse the repository at this point in the history
  • Loading branch information
pinkisemils committed Dec 13, 2024
1 parent 181d35f commit 3ebf0a8
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 8 deletions.
5 changes: 0 additions & 5 deletions ios/MullvadRustRuntime/EphemeralPeerExchangeActor.swift
Original file line number Diff line number Diff line change
Expand Up @@ -62,10 +62,6 @@ public class EphemeralPeerExchangeActor: EphemeralPeerExchangeActorProtocol {
endCurrentNegotiation()
let negotiator = negotiationProvider.init()

let gatewayAddress = LocalNetworkIPs.gatewayAddress.rawValue
let IPv4Gateway = IPv4Address(gatewayAddress)!
let endpoint = NWHostEndpoint(hostname: gatewayAddress, port: "\(CONFIG_SERVICE_PORT)")

// This will become the new private key of the device
let ephemeralSharedKey = PrivateKey()

Expand All @@ -79,7 +75,6 @@ public class EphemeralPeerExchangeActor: EphemeralPeerExchangeActorProtocol {
)

if !negotiator.startNegotiation(
gatewayIP: IPv4Gateway,
devicePublicKey: privateKey.publicKey,
presharedKey: ephemeralSharedKey,
peerReceiver: packetTunnel,
Expand Down
2 changes: 0 additions & 2 deletions ios/MullvadRustRuntime/EphemeralPeerNegotiator.swift
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ import WireGuardKitTypes
// swiftlint:disable function_parameter_count
public protocol EphemeralPeerNegotiating {
func startNegotiation(
gatewayIP: IPv4Address,
devicePublicKey: PublicKey,
presharedKey: PrivateKey,
peerReceiver: any TunnelProvider,
Expand All @@ -33,7 +32,6 @@ public class EphemeralPeerNegotiator: EphemeralPeerNegotiating {
var cancelToken: OpaquePointer?

public func startNegotiation(
gatewayIP: IPv4Address,
devicePublicKey: PublicKey,
presharedKey: PrivateKey,
peerReceiver: any TunnelProvider,
Expand Down
2 changes: 1 addition & 1 deletion ios/PacketTunnelCore/Actor/PacketTunnelActor.swift
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ public actor PacketTunnelActor {

case let .cacheActiveKey(lastKeyRotation):
cacheActiveKey(lastKeyRotation: lastKeyRotation)
case var .reconfigureForEphemeralPeer(configuration, configurationSemaphore):
case let .reconfigureForEphemeralPeer(configuration, configurationSemaphore):
do {
try await updateEphemeralPeerNegotiationState(configuration: configuration)
} catch {
Expand Down

0 comments on commit 3ebf0a8

Please sign in to comment.