make SSLSocket Factory
Creates an SSLSocketFactory bound to this TrustPin instance.
The returned factory performs TrustPin certificate pinning validation on every TLS connection. Use with OkHttp or HttpsURLConnection:
val pin = TrustPin.default
val client = OkHttpClient.Builder()
.sslSocketFactory(pin.makeSSLSocketFactory(), pin.makeTrustManager())
.build()Content copied to clipboard
Return
A new SSLSocketFactory with TrustPin validation
Throws
if SSL context creation fails