- Sort Score
- Result 10 results
- Languages All
Results 1 - 7 of 7 for acceptedIssuers (0.15 sec)
-
okhttp-tls/src/test/java/okhttp3/tls/HandshakeCertificatesTest.kt
val handshakeCertificates = HandshakeCertificates.Builder() .addPlatformTrustedCertificates() .build() val acceptedIssuers = handshakeCertificates.trustManager.acceptedIssuers val names = acceptedIssuers .map { it.subjectDN.name } .toSet() // It's safe to assume all platforms will have a major Internet certificate issuer.
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Thu Apr 11 22:09:35 UTC 2024 - 7.1K bytes - Viewed (0) -
okhttp-tls/src/main/kotlin/okhttp3/tls/internal/InsecureExtendedTrustManager.kt
private val delegate: X509ExtendedTrustManager, private val insecureHosts: List<String>, ) : X509ExtendedTrustManager() { override fun getAcceptedIssuers(): Array<X509Certificate> = delegate.acceptedIssuers override fun checkServerTrusted( chain: Array<out X509Certificate>, authType: String, socket: Socket, ) { if (socket.peerName() !in insecureHosts) {
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 2.6K bytes - Viewed (0) -
okhttp-tls/src/main/kotlin/okhttp3/tls/internal/InsecureAndroidTrustManager.kt
} catch (e: InvocationTargetException) { throw e.targetException } } override fun getAcceptedIssuers(): Array<X509Certificate> = delegate.acceptedIssuers override fun checkClientTrusted( chain: Array<out X509Certificate>, authType: String?, ) = throw CertificateException("Unsupported operation") override fun checkServerTrusted(
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 2.4K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/internal/platform/Platform.kt
BasicCertificateChainCleaner(buildTrustRootIndex(trustManager)) open fun buildTrustRootIndex(trustManager: X509TrustManager): TrustRootIndex = BasicTrustRootIndex(*trustManager.acceptedIssuers) open fun newSslSocketFactory(trustManager: X509TrustManager): SSLSocketFactory { try { return newSSLContext().apply { init(null, arrayOf<TrustManager>(trustManager), null)
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 9.8K bytes - Viewed (0) -
okhttp-tls/src/main/kotlin/okhttp3/tls/HandshakeCertificates.kt
*/ fun addPlatformTrustedCertificates() = apply { val platformTrustManager = Platform.get().platformTrustManager() Collections.addAll(trustedCertificates, *platformTrustManager.acceptedIssuers) } /** * Configures this to not authenticate the HTTPS server on to [hostname]. This makes the user * vulnerable to man-in-the-middle attacks and should only be used only in private development
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 8.5K bytes - Viewed (0) -
android-test/src/androidTest/java/okhttp/android/test/OkHttpTest.kt
enableTls() val certificatePinner = CertificatePinner.Builder() .add( server.hostName, CertificatePinner.pin(handshakeCertificates.trustManager.acceptedIssuers[0]), ) .build() client = client.newBuilder().certificatePinner(certificatePinner).build() server.enqueue(MockResponse(body = "abc"))
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Sat Jan 20 10:30:28 UTC 2024 - 27K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/URLConnectionTest.kt
private class RecordingTrustManager(private val delegate: X509TrustManager) : X509TrustManager { val calls: MutableList<String> = ArrayList() override fun getAcceptedIssuers(): Array<X509Certificate> = delegate.acceptedIssuers override fun checkClientTrusted( chain: Array<X509Certificate>, authType: String, ) { calls.add("checkClientTrusted " + certificatesToString(chain)) }
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Sat Jan 20 10:30:28 UTC 2024 - 131.7K bytes - Viewed (0)