Package anvil.server

Examples of anvil.server.RedirectException


      if (searchResult != null && searchResult.length > 0) {
        context.setCitizen(searchResult[0]);
        context.log().info("web: ipauthentication ok");
       
        if (context.getOriginalPathinfo().equals(loginPath)) {
          throw new RedirectException(context.getSession().getId(), forwardPath);
        }
        return true;
      }

      String username = request.getParameter("webauth.username");
      String password = request.getParameter("webauth.password");
     
      context.getSession().removeAttribute("webauth.failedUser");
     
      if (username != null && password != null && username.length() > 0) {
        citizen = realm.getCitizen(username);
        context.log().info("username: '"+username+"' citizen: "+citizen);
        if (citizen != null && citizen.verifyCredentials(password)) {
          context.setCitizen(citizen);
          context.log().info("web: authentication ok");
         
          if (context.getOriginalPathinfo().equals(loginPath)) {
            throw new RedirectException(context.getSession().getId(), forwardPath);
          }
          return true;
        } else {
          context.log().info("web: no user found or wrong pass");
          context.getSession().setAttribute("webauth.failedUser", username);
View Full Code Here

TOP

Related Classes of anvil.server.RedirectException

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.