code: protected X509Certificate[] getX509CertificateObjectChain(X509Certificate[] certs)
              throws GeneralSecurityException {
          X509Certificate[] bcCerts = new X509Certificate[certs.length];
          for (int i = 0; i < certs.length; i++) {
              if (!(certs[i] instanceof X509CertificateObject)) {
                  bcCerts[i] = CertificateLoadUtil.loadCertificate(new ByteArrayInputStream(certs[i].getEncoded()));
              } else {
                  bcCerts[i] = certs[i];
              }
          }
          return bcCerts;
      }
docs: Returns a chain of X509Certificate's that are instances of X509CertificateObject
  This is related to http://bugzilla.globus.org/globus/show_bug.cgi?id=4933
  @param certs input certificate chain
  @return a new chain where all X509Certificate's are instances of X509CertificateObject
  @throws GeneralSecurityException when failing to get load certificate from encoding