An advanced Ethereum/EVM mobile wallet
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
alpha-wallet-ios/Trust/Transactions/Coordinators/TrustProvider.swift

25 lines
834 B

// Copyright SIX DAY LLC. All rights reserved.
import Alamofire
import Foundation
import Moya
struct TrustProviderFactory {
static let policies: [String: ServerTrustPolicy] = [
:
// Disabled until: https://github.com/TrustWallet/trust-wallet-ios/pull/129#issuecomment-353718512
// "trustwalletapp.com": .pinPublicKeys(
// publicKeys: ServerTrustPolicy.publicKeys(in: Bundle.main),
// validateCertificateChain: true,
// validateHost: true
// ),
]
static func makeProvider() -> MoyaProvider<TrustService> {
let manager = Manager(
configuration: URLSessionConfiguration.default,
serverTrustPolicyManager: ServerTrustPolicyManager(policies: policies)
)
return MoyaProvider<TrustService>(manager: manager)
}
}