Examples of AuthnRequestType


Examples of org.jboss.identity.federation.saml.v2.protocol.AuthnRequestType

                 

               if(trace)
                  log.trace("Roles have been determined:Creating response");

               AuthnRequestType art = (AuthnRequestType) requestAbstractType;
               destination = art.getAssertionConsumerServiceURL();

               samlResponse =
                  webRequestUtil.getResponse(destination,
                        userPrincipal, roles,
                        this.identityURL, this.assertionValidity, this.signOutgoingMessages);
View Full Code Here

Examples of org.jboss.identity.federation.saml.v2.protocol.AuthnRequestType

         if(userPrincipal == null)
         {
            String relayState = null;
            try
            {
               AuthnRequestType authnRequest = createSAMLRequest(serviceURL, identityURL);
               sendRequestToIDP(authnRequest, relayState, response);
            }
            catch (Exception e)
            {
               throw new ServletException(e);
View Full Code Here

Examples of org.jboss.identity.federation.saml.v2.protocol.AuthnRequestType

                  List<String> roles = rg.generateRoles(userPrincipal);
                 
                  log.trace("Roles have been determined:Creating response");

                  AuthnRequestType art = (AuthnRequestType) requestAbstractType;
                  destination = art.getAssertionConsumerServiceURL();
                 
                  samlResponse =
                     webRequestUtil.getResponse(destination,
                           userPrincipal, roles,
                           this.identityURL, this.assertionValidity, this.signOutgoingMessages);
View Full Code Here

Examples of org.jboss.identity.federation.saml.v2.protocol.AuthnRequestType

        
         SAML2Request samlRequest = new SAML2Request();
         String id = IDGenerator.create("ID_");
         try
         {
            AuthnRequestType authn = samlRequest.createAuthnRequestType(id,
                issuerValue, response.getDestination(), issuerValue);
           
            response.setResultingDocument(samlRequest.convert(authn));
         }
         catch (Exception e)
View Full Code Here

Examples of org.jboss.identity.federation.saml.v2.protocol.AuthnRequestType

         {
            String relayState = null;
            try
           
               //TODO: use the handlers to generate the request
               AuthnRequestType authnRequest = createSAMLRequest(serviceURL, identityURL);
               sendRequestToIDP(authnRequest, relayState, response);
            }
            catch (Exception e)
            {
               throw new ServletException(e);
View Full Code Here

Examples of org.jboss.identity.federation.saml.v2.protocol.AuthnRequestType

     
      @SuppressWarnings("unchecked")
      public void handleRequestType( SAML2HandlerRequest request,
            SAML2HandlerResponse response ) throws ProcessingException
      {
         AuthnRequestType art = (AuthnRequestType) request.getSAML2Object();
         HttpSession session = BaseSAML2Handler.getHttpSession(request);
         Principal userPrincipal = (Principal) session.getAttribute(GeneralConstants.PRINCIPAL_ID);
         List<String> roles = (List<String>) session.getAttribute(GeneralConstants.ROLES_ID);
         try
         {
            Map<String,Object> attribs = (Map<String, Object>) request.getOptions().get(GeneralConstants.ATTRIBUTES);
            long assertionValidity = (Long) request.getOptions().get(GeneralConstants.ASSERTIONS_VALIDITY);
            String destination = art.getAssertionConsumerServiceURL();
            Document samlResponse = this.getResponse(destination,
                  userPrincipal, roles, request.getIssuer().getValue(),
                  attribs,
                  assertionValidity);
           
View Full Code Here

Examples of org.jboss.identity.federation.saml.v2.protocol.AuthnRequestType

    */
   public static JAXBElement<?> get(RequestAbstractType requestAbstractType)
   {
      if(requestAbstractType instanceof AuthnRequestType)
      {
         AuthnRequestType art = (AuthnRequestType) requestAbstractType;
         return SAMLProtocolFactory.getObjectFactory().createAuthnRequest(art);
      }
     
      if(requestAbstractType instanceof LogoutRequestType)
      {
View Full Code Here

Examples of org.jboss.identity.federation.saml.v2.protocol.AuthnRequestType

    * Create a AuthnRequestType
    * @return
    */
   public static AuthnRequestType createAuthnRequestType()
   {
      AuthnRequestType authnRequestType = SAMLProtocolFactory.getObjectFactory().createAuthnRequestType();
      return authnRequestType;
   }
View Full Code Here

Examples of org.jboss.identity.federation.saml.v2.protocol.AuthnRequestType

   public static AuthnRequestType createAuthnRequestType(String id,
         String assertionConsumerURL, String destination, String issuerValue) throws Exception
   {
      XMLGregorianCalendar issueInstant = XMLTimeUtil.getIssueInstant();
     
      AuthnRequestType authnRequest = SAMLProtocolFactory.getObjectFactory().createAuthnRequestType();
      authnRequest.setID(id);
      authnRequest.setVersion(JBossSAMLConstants.VERSION_2_0.get());
      authnRequest.setAssertionConsumerServiceURL(assertionConsumerURL);
      authnRequest.setDestination(destination);
      authnRequest.setIssueInstant(issueInstant);
     
      //Create an issuer
      NameIDType issuer = JBossSAMLBaseFactory.createNameID();
      issuer.setValue(issuerValue);
     
      authnRequest.setIssuer(issuer);
     
      return authnRequest;
     
   }
View Full Code Here

Examples of org.jboss.identity.federation.saml.v2.protocol.AuthnRequestType

    */
   public static JAXBElement<?> get(RequestAbstractType requestAbstractType)
   {
      if(requestAbstractType instanceof AuthnRequestType)
      {
         AuthnRequestType art = (AuthnRequestType) requestAbstractType;
         return SAMLProtocolFactory.getObjectFactory().createAuthnRequest(art);
      }
     
      if(requestAbstractType instanceof LogoutRequestType)
      {
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.