Examples of Admin


Examples of org.ejbca.core.model.log.Admin

  public int isApproved(int approvalId) throws ApprovalException, EjbcaException, ApprovalRequestExpiredException{
    EjbcaWSHelper ejbhelper = new EjbcaWSHelper(wsContext, authorizationSession, caAdminSession, certificateProfileSession, certificateStoreSession, endEntityProfileSession, hardTokenSession, userAdminSession);

        final IPatternLogger logger = TransactionLogger.getPatternLogger();
        try {
            final Admin admin = ejbhelper.getAdmin(true);
            logAdminName(admin,logger);
      return approvalSession.isApproved(admin, approvalId);
    } catch (AuthorizationDeniedException e) {
            throw EjbcaWSHelper.getEjbcaException(e, logger, ErrorCode.NOT_AUTHORIZED, Level.ERROR);
        } catch (RuntimeException e) {  // EJBException, ClassCastException, ...
View Full Code Here

Examples of org.ejbca.core.model.log.Admin

   */
  public Certificate getCertificate(String certSNinHex, String issuerDN) throws CADoesntExistsException,
    AuthorizationDeniedException, EjbcaException {
    Certificate retval = null;
    EjbcaWSHelper ejbhelper = new EjbcaWSHelper(wsContext, authorizationSession, caAdminSession, certificateProfileSession, certificateStoreSession, endEntityProfileSession, hardTokenSession, userAdminSession);
    Admin admin = ejbhelper.getAdmin(true);
    String bcString = CertTools.stringToBCDNString(issuerDN);
    int caid = bcString.hashCode();
        final IPatternLogger logger = TransactionLogger.getPatternLogger();
        logAdminName(admin,logger);
    try {
View Full Code Here

Examples of org.ejbca.core.model.log.Admin

   * @see org.ejbca.core.protocol.ws.common.IEjbcaWS#getAvailableCAs()
   */
  public NameAndId[] getAvailableCAs() throws EjbcaException, AuthorizationDeniedException {
    TreeMap<String,Integer> ret = new TreeMap<String,Integer>();
    EjbcaWSHelper ejbhelper = new EjbcaWSHelper(wsContext, authorizationSession, caAdminSession, certificateProfileSession, certificateStoreSession, endEntityProfileSession, hardTokenSession, userAdminSession);
    Admin admin = ejbhelper.getAdmin(true);
        final IPatternLogger logger = TransactionLogger.getPatternLogger();
        logAdminName(admin,logger);
    try {
      Collection<Integer> caids = caSession.getAvailableCAs(admin);
      HashMap<Integer, String> map = caAdminSession.getCAIdToNameMap(admin);
View Full Code Here

Examples of org.ejbca.core.model.log.Admin

   * @see org.ejbca.core.protocol.ws.common.IEjbcaWS#getAuthorizedEndEntityProfiles()
   */
  public NameAndId[] getAuthorizedEndEntityProfiles()
      throws AuthorizationDeniedException, EjbcaException {
    EjbcaWSHelper ejbhelper = new EjbcaWSHelper(wsContext, authorizationSession, caAdminSession, certificateProfileSession, certificateStoreSession, endEntityProfileSession, hardTokenSession, userAdminSession);
    Admin admin = ejbhelper.getAdmin();
    TreeMap<String,Integer> ret = new TreeMap<String,Integer>();
        final IPatternLogger logger = TransactionLogger.getPatternLogger();
        logAdminName(admin,logger);
    try {
      Collection<Integer> ids = endEntityProfileSession.getAuthorizedEndEntityProfileIds(admin);
View Full Code Here

Examples of org.ejbca.core.model.log.Admin

    /**
   * @see org.ejbca.core.protocol.ws.common.IEjbcaWS#getAvailableCertificateProfiles()
   */
  public NameAndId[] getAvailableCertificateProfiles(int entityProfileId) throws AuthorizationDeniedException, EjbcaException {
    EjbcaWSHelper ejbhelper = new EjbcaWSHelper(wsContext, authorizationSession, caAdminSession, certificateProfileSession, certificateStoreSession, endEntityProfileSession, hardTokenSession, userAdminSession);
    Admin admin = ejbhelper.getAdmin();
    TreeMap<String,Integer> ret = new TreeMap<String,Integer>();
        final IPatternLogger logger = TransactionLogger.getPatternLogger();
        logAdminName(admin,logger);
    try {
      EndEntityProfile profile = endEntityProfileSession.getEndEntityProfile(admin, entityProfileId);
View Full Code Here

Examples of org.ejbca.core.model.log.Admin

  /**
   * @see org.ejbca.core.protocol.ws.common.IEjbcaWS#getAvailableCAsInProfile()
   */
  public NameAndId[] getAvailableCAsInProfile(int entityProfileId) throws AuthorizationDeniedException, EjbcaException {
    EjbcaWSHelper ejbhelper = new EjbcaWSHelper(wsContext, authorizationSession, caAdminSession, certificateProfileSession, certificateStoreSession, endEntityProfileSession, hardTokenSession, userAdminSession);
    Admin admin = ejbhelper.getAdmin();
    TreeMap<String,Integer> ret = new TreeMap<String,Integer>();
        final IPatternLogger logger = TransactionLogger.getPatternLogger();
        logAdminName(admin,logger);
    try {
      EndEntityProfile profile = endEntityProfileSession.getEndEntityProfile(admin, entityProfileId);
View Full Code Here

Examples of org.ejbca.core.model.log.Admin

   */
  public void createCRL(String caname) throws CADoesntExistsException, ApprovalException, EjbcaException, ApprovalRequestExpiredException{
        final IPatternLogger logger = TransactionLogger.getPatternLogger();
    try {
      EjbcaWSHelper ejbhelper = new EjbcaWSHelper(wsContext, authorizationSession, caAdminSession, certificateProfileSession, certificateStoreSession, endEntityProfileSession, hardTokenSession, userAdminSession);
      Admin admin = ejbhelper.getAdmin(true);
            logAdminName(admin,logger);
      CA ca = caSession.getCA(admin, caname);
      crlStoreSession.run(admin, ca);
    } catch (AuthorizationDeniedException e) {
            throw EjbcaWSHelper.getEjbcaException(e, logger, ErrorCode.NOT_AUTHORIZED, Level.ERROR);
View Full Code Here

Examples of org.exist.soap.Admin

    "</xu:insert-after>" +
    "</xu:modifications>";
   
    public static void main( String[] args ) throws Exception {
        AdminService adminService = new AdminServiceLocator();
        Admin admin = adminService.getAdmin();
        QueryService queryService = new QueryServiceLocator();
        Query query = queryService.getQuery();
       
    String session = admin.connect("guest", "guest");
    admin.store(session, document.getBytes(UTF_8), "UTF-8", XmldbURI.ROOT_COLLECTION + "/test/notes.xml", true);
    admin.xupdateResource(session, XmldbURI.ROOT_COLLECTION + "/test/notes.xml", xupdate);
   
    String data = query.getResource(session,
        XmldbURI.ROOT_COLLECTION + "/test/notes.xml",
      true, true);
    System.out.println(data);
    admin.disconnect(session);
    }
View Full Code Here

Examples of org.jacorb.imr.Admin

                                           String host,
                                           boolean edit_existing )
    {
        try
        {
            Admin admin =
                AdminHelper.narrow( orb.resolve_initial_references("ImplementationRepository"));

            Configuration config = ((org.jacorb.orb.ORB)orb).getConfiguration();
            Logger logger = config.getLogger("jacorb.imr.manager");

            ServerInfo info = null;

            try
            {
                info = admin.get_server_info(server);
            }
            catch (UnknownServerName n)
            {
                    logger.warn("Unknown Server name", n);
            }

            if (info == null)
            {
                admin.register_server(server, command, host);
            }
            else if ((info != null) && edit_existing)
            {
                admin.edit_server(server, command, host);
            }
        }
        catch (Exception e)
        {
            logger.warn("unexpected exception", e);
View Full Code Here

Examples of org.jacorb.imr.Admin

     */
    public static String getAnyHostName(org.omg.CORBA.ORB orb)
    {
        try
        {
            Admin admin =
                AdminHelper.narrow( orb.resolve_initial_references("ImplementationRepository"));

            HostInfo[] hosts = admin.list_hosts();

            if (hosts.length > 0)
            {
                return hosts[0].name;
            }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.