code: private void handleCertificateAuthenticator(X509Certificate[] certChain,
                                                  CertificateAuthenticator certAuthen) throws Exception {
          String type = certAuthen.getType();
          if (type == null)
              type = AccessIdUtil.TYPE_USER;
          String realm = certAuthen.getRealm();
          if (realm == null)
              realm = "defaultRealm";
          authenticatedId = certAuthen.getUsername();
          username = authenticatedId;
          String accessId = AccessIdUtil.createAccessId(type, realm, authenticatedId);
          addCredentials(accessId);
      }
docs: Get the accessid components (type, realm, username) from the
  CertificateAuthenticator and create the Principal and credentials
  
  @param certChain
  @param bob