setTrustedServerCertificates(_:)
Sets trusted EAP server certificates for an enterprise Wi-Fi or Hotspot 2.0 network.
Declaration
func setTrustedServerCertificates(_ certificates: [Any]) -> BoolParameters
- certificates:
An array of Seccertificate objects. The EAP peer uses these certificates to evaluate the trust of the server certificate chain.
Return Value
Returns false if any element in the array is not an object of type SecCertificate or if the OS fails to find a persistent reference for each element from the application’s keychain; else return true.
Discussion
Your app must store the certificates in keychain access group $(TeamIdentifierPrefix)com.apple.networkextensionsharing. The OS uses SecItemCopyMatching(_:_:) to obtain a persistent reference to each certificate from the application’s keychain and uses it during EAP authentication.
The number of elements in the certificate array may not be more than 10.