2
0
mirror of https://github.com/KDE/kdeconnect-android synced 2025-08-31 06:05:12 +00:00

Do not force TLS v1

Stop specifying the TLS version we want and let the system chose

Co-authored-by: Daniel Tang <danielzgtg.opensource@gmail.com>
This commit is contained in:
Albert Vaca Cintora
2023-04-10 10:53:17 +02:00
parent e07fe54d5c
commit e2dbc39e3a

View File

@@ -209,7 +209,7 @@ public class SslHelper {
trustManagerFactory.init(keyStore); trustManagerFactory.init(keyStore);
// Setup custom trust manager if device not trusted // Setup custom trust manager if device not trusted
SSLContext tlsContext = SSLContext.getInstance("TLSv1"); //Newer TLS versions are only supported on API 16+ SSLContext tlsContext = SSLContext.getInstance("TLS");
if (isDeviceTrusted) { if (isDeviceTrusted) {
tlsContext.init(keyManagerFactory.getKeyManagers(), trustManagerFactory.getTrustManagers(), RandomHelper.secureRandom); tlsContext.init(keyManagerFactory.getKeyManagers(), trustManagerFactory.getTrustManagers(), RandomHelper.secureRandom);
} else { } else {