DefaultTrustStoreSession
public class DefaultTrustStoreSession
extension DefaultTrustStoreSession: TrustStoreSession
TrustStoreSession acts as an interactor/mediator for the TrustStoreClient and TrustStoreStorage
-
Initialize a Truststore Session
Declaration
Swift
public convenience init( serverURL: URL, trustAnchor: TrustAnchor, trustStoreStorage: TrustStoreStorage, httpClient: HTTPClient = DefaultHTTPClient(urlSessionConfiguration: .ephemeral) )
Parameters
serverURL
the server URL
trustAnchor
Trust Anchor (root certificate) for further certificate validation
trustStoreStorage
the backing session storage
httpClient
the HTTP client
-
Declaration
Swift
public func reset()
-
Declaration
Swift
public func loadVauCertificate() -> AnyPublisher<X509, TrustStoreError>
-
Declaration
Swift
public func validate(certificate: X509) -> AnyPublisher<Bool, TrustStoreError>