Package org.jasig.cas.client.validation

Examples of org.jasig.cas.client.validation.Cas20ProxyTicketValidator.validate()


    Cas20ProxyTicketValidator ticketValidator = new Cas20ProxyTicketValidator(casServerUrl);
      ticketValidator.setRenew(this.renewTicket);
     
      //String serviceUrl = "http://"+ httpRequest.getServerName() +":" + httpRequest.getServerPort() +
      //httpRequest.getContextPath() +"/private/classic";
      Assertion assertion = ticketValidator.validate(ticket, this.casServiceUrl);
     
      log.debug("------------------------------------------------------------------------------------");
      log.debug("Service: "+this.casServiceUrl);
      log.debug("Principal: "+assertion.getPrincipal().getName());
      log.debug("------------------------------------------------------------------------------------");
View Full Code Here


  try {
    AttributePrincipal principal = null;
    Cas20ProxyTicketValidator sv = new Cas20ProxyTicketValidator(validateUrl);
    sv.setAcceptAnyProxy(true);

      Assertion a = sv.validate(ticket, validateService);
    principal = a.getPrincipal();
    logger.debug("Ticket is VALID, username=" + principal.getName());
     
  } catch (TicketValidationException e) {
    logger.error("An exception occured while validating the cas token");
View Full Code Here

    Cas20ProxyTicketValidator ticketValidator = new Cas20ProxyTicketValidator(casServerUrl);
      ticketValidator.setRenew(this.renewTicket);
     
      //String serviceUrl = "http://"+ httpRequest.getServerName() +":" + httpRequest.getServerPort() +
      //httpRequest.getContextPath() +"/private/classic";
      Assertion assertion = ticketValidator.validate(ticket, this.casServiceUrl);
     
      log.debug("------------------------------------------------------------------------------------");
      log.debug("Service: "+this.casServiceUrl);
      log.debug("Principal: "+assertion.getPrincipal().getName());
      log.debug("------------------------------------------------------------------------------------");
View Full Code Here

    Cas20ProxyTicketValidator ticketValidator = new Cas20ProxyTicketValidator(casServerUrl);
    ticketValidator.setRenew(this.renewTicket);
   
    String serviceUrl = "http://"+ httpRequest.getServerName() +":" + httpRequest.getServerPort() +
    httpRequest.getContextPath() +"/private/classic";
    Assertion assertion = ticketValidator.validate(ticket, serviceUrl);
   
    log.debug("------------------------------------------------------------------------------------");
    log.debug("Service: "+serviceUrl);
    log.debug("Principal: "+assertion.getPrincipal().getName());
    log.debug("------------------------------------------------------------------------------------");
View Full Code Here

        validator.setProxyCallbackUrl(GeoServerCasConstants
                .createProxyCallBackURl(proxyCallbackUrlPrefix.toExternalForm()));
        validator.setProxyGrantingTicketStorage(GeoServerExtensions
                .bean(ProxyGrantingTicketStorage.class));

        Assertion result = validator.validate(ticket, serviceUrl.toExternalForm());

        assertNotNull(result);
        return result;

    }
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.