certprofiles.addAll(certificatestoresession.getAuthorizedCertificateProfileIds(admin, SecConst.CERTTYPE_ENDENTITY)); certprofiles.addAll(certificatestoresession.getAuthorizedCertificateProfileIds(admin, SecConst.CERTTYPE_ROOTCA)); certprofiles.addAll(certificatestoresession.getAuthorizedCertificateProfileIds(admin, SecConst.CERTTYPE_SUBCA));
certprofiles.addAll(certificatestoresession.getAuthorizedCertificateProfileIds(admin, CertificateDataBean.CERTTYPE_ENDENTITY)); certprofiles.addAll(certificatestoresession.getAuthorizedCertificateProfileIds(admin, CertificateDataBean.CERTTYPE_ROOTCA)); certprofiles.addAll(certificatestoresession.getAuthorizedCertificateProfileIds(admin, CertificateDataBean.CERTTYPE_SUBCA));
    public TreeMap getEditCertificateProfileNames(boolean includefixedhardtokenprofiles){      if(allprofilenames==null){      	// check if administrator      	boolean superadministrator = false;		try{		  superadministrator = authorizationsession.isAuthorizedNoLog(admin, "/super_administrator");		}catch(AuthorizationDeniedException ade){}      	        allprofilenames = new TreeMap();        Iterator iter= null;          if(includefixedhardtokenprofiles){          iter = certificatestoresession.getAuthorizedCertificateProfileIds(admin, 0).iterator();        }else{          ArrayList certprofiles = new ArrayList();		  certprofiles.addAll(certificatestoresession.getAuthorizedCertificateProfileIds(admin, SecConst.CERTTYPE_ENDENTITY));		  certprofiles.addAll(certificatestoresession.getAuthorizedCertificateProfileIds(admin, SecConst.CERTTYPE_ROOTCA));		  certprofiles.addAll(certificatestoresession.getAuthorizedCertificateProfileIds(admin, SecConst.CERTTYPE_SUBCA));		  iter = certprofiles.iterator();        }        HashMap idtonamemap = certificatestoresession.getCertificateProfileIdToNameMap(admin);        while(iter.hasNext()){                  Integer id = (Integer) iter.next();          CertificateProfile certprofile = certificatestoresession.getCertificateProfile(admin,id.intValue());           // If not superadministrator, then should only end entity profiles be added.          if(superadministrator || certprofile.getType() == CertificateProfile.TYPE_ENDENTITY){                                  // if default profiles, add fixed to name.            if(id.intValue() <= SecConst.FIXED_CERTIFICATEPROFILE_BOUNDRY ||                (!superadministrator && certprofile.isApplicableToAnyCA()))			  allprofilenames.put(idtonamemap.get(id) + " (FIXED)",id);               else		      allprofilenames.put(idtonamemap.get(id),id);                    }        }        }      return allprofilenames;      }    