Package com.iplanet.sso

Examples of com.iplanet.sso.SSOToken


      HttpServletRequest httpRequest = (HttpServletRequest) request;
      HttpSession session = httpRequest.getSession();
      request.setAttribute("ssoEnabled", "true");

      SSOToken token = getToken();

      String requestURI = request.getRequestURI();

      // When token is not present and secured portal url is requested

      if (isSecuredURI(requestURI) && token == null)
      {
        
         // Perform OpenSSO login by going to the OpenSSO authentication server

         redirectToOpenSSOLogin(request, response);
         return;
      }

      // When token present and valid

      if (token != null && isTokenValid(token))
      {

         try
         {
            // Perform the portal JAAS authentication

            String user = token.getProperty("UserId");
            request.setAttribute("ssoSuccess", new Boolean(true));
            Principal principal = ((Context) this.container).getRealm().authenticate(user, (String) null);
            if (principal != null)
            {
               this.register(request, response, principal, getAuthType(), user,
View Full Code Here


      try {
         HttpServletRequest request = (HttpServletRequest) PolicyContext.getContext(WEB_REQUEST_KEY);

         SSOTokenManager manager = SSOTokenManager.getInstance();

         SSOToken token = manager.createSSOToken(request);

         return token;

      } catch (Exception e) {
         log.debug("Failed to obtain SSO Token: " + e);
View Full Code Here

        PasswordValidationCallback.PlainTextPasswordRequest plainTextRequest =
                (PasswordValidationCallback.PlainTextPasswordRequest) request;
        String username = plainTextRequest.getUsername();
        String password = plainTextRequest.getPassword();
       
        SSOToken token = authenticateUser(username, password);

  debug.message("Authenticated username/pasword SSOToken is "+token);

        updateUserSubject(token);
View Full Code Here

      private SSOToken authenticateUser(String username, String password) throws PasswordValidationCallback.PasswordValidationException
    {
  debug.message("Entering SampleAMUsernamePasswordValidator.authenticateUser");

        AuthContext ac = null;
        SSOToken token = null;

        debug.message("Username is "+username);
        debug.message("OrgName is "+orgName);

        try {
View Full Code Here

   
    public boolean isAuthorized(Subject subject, String appliesTo, String tokenType, String keyType)
    {
        String serviceName = "iPlanetAMWebAgentService";
        String action = "POST";
        SSOToken token = getSSOToken(subject);

        try
        {
            debug.message("Authorizing access - SSOToken is "+token);
            debug.message("Checking policy for "+action+" on URL "+appliesTo);
View Full Code Here

TOP

Related Classes of com.iplanet.sso.SSOToken

Copyright © 2018 www.massapicom. 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.