On 1 Dec 2015, at 07:46, Kevin Yu <kevi...@draytek.com> wrote:

> I think we can use the NWTCPConnectionAuthenticationDelegate and it’s 
> function evaluateTrustForConnection() to do the trick, however, I did not 
> found how to write this function in order to create a SecTrustRef and send 
> out via completion handler.

The intent is that you create a trust object by calling 
SecTrustCreateWithCertificates.  This takes two input parameters:

* certificates -- You get this from peerCertificateChain parameter of 
-evaluateTrustForConnection:peerCertificateChain:completionHandler:.

* policies -- For TLS you'd usually create this by calling SecPolicyCreateSSL.

Share and Enjoy
--
Quinn "The Eskimo!"                    <http://www.apple.com/developer/>
Apple Developer Relations, Developer Technical Support, Core OS/Hardware



 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Macnetworkprog mailing list      (Macnetworkprog@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/macnetworkprog/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to