blob: c8dcd122b0888ecc50c69a63fb579495dd2ab482 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
|
//
// DeviceCheckRemoteServiceProtocol.swift
// PacketTunnel
//
// Created by pronebird on 07/06/2023.
// Copyright © 2025 Mullvad VPN AB. All rights reserved.
//
import Foundation
import MullvadTypes
import WireGuardKitTypes
/// A protocol that formalizes remote service dependency used by `DeviceCheckOperation`.
protocol DeviceCheckRemoteServiceProtocol {
func getAccountData(accountNumber: String, completion: @escaping @Sendable (Result<Account, Error>) -> Void)
-> Cancellable
func getDevice(
accountNumber: String,
identifier: String,
completion: @escaping @Sendable (Result<Device, Error>) -> Void
)
-> Cancellable
func rotateDeviceKey(
accountNumber: String,
identifier: String,
publicKey: PublicKey,
completion: @escaping @Sendable (Result<Device, Error>) -> Void
) -> Cancellable
}
|