private static @NotNull List<X509TrustManager> getSystemTrustManagers() {
    List<X509TrustManager> result = new ArrayList<>();

    X509TrustManager osManager = getOperatingSystemTrustManager();
    if (osManager != null) {
      result.add(osManager);
    }

    X509TrustManager javaRuntimeManager = getJavaRuntimeDefaultTrustManager();
    if (javaRuntimeManager != null) {
      result.add(javaRuntimeManager);
    }

    return result;
  }
private static @NotNull List<X509TrustManager> getSystemTrustManagers()