Code example for X509TrustManager

Methods: checkServerTrusted

0
   * Delegate to the default trust manager. 
   */ 
  public void checkServerTrusted(X509Certificate[] chain, String authType)
      throws CertificateException { 
    try { 
      sunJSSEX509TrustManager.checkServerTrusted(chain, authType);
    } catch (CertificateException excep) {
      /* 
       * Possibly pop up a dialog box asking whether to trust the cert chain. 
       */ 
    } 
  } 
 
  /* 
   * Merely pass this through. 
   */ 
  public X509Certificate[] getAcceptedIssuers() {
    return sunJSSEX509TrustManager.getAcceptedIssuers();
  } 
 
}