类 AuthServlet

java.lang.Object
jakarta.servlet.GenericServlet
jakarta.servlet.http.HttpServlet
com.sh.wf.servlet.SHServletBase
com.sh.system.servlet.AuthServlet
所有已实现的接口:
jakarta.servlet.Servlet, jakarta.servlet.ServletConfig, Serializable

@WebServlet("/auth") public class AuthServlet extends SHServletBase

Description: 授权逻辑

Title:首亨软件 - 聚天平台

从以下版本开始:
2018年11月13日
另请参阅:
  • 字段详细资料

    • LOGIN_USER_NOT_EXISTS

      public static String LOGIN_USER_NOT_EXISTS
    • LOGIN_PWD_ERROR

      public static String LOGIN_PWD_ERROR
  • 构造器详细资料

    • AuthServlet

      public AuthServlet()
  • 方法详细资料

    • doPost

      protected void doPost(jakarta.servlet.http.HttpServletRequest request, jakarta.servlet.http.HttpServletResponse response) throws jakarta.servlet.ServletException, IOException
      覆盖:
      doPost 在类中 jakarta.servlet.http.HttpServlet
      抛出:
      jakarta.servlet.ServletException
      IOException
    • returnForward

      public void returnForward(jakarta.servlet.http.HttpServletRequest request, jakarta.servlet.http.HttpServletResponse response, String forward, String msgType, String msgStr)
    • returnForward

      public void returnForward(jakarta.servlet.http.HttpServletRequest request, jakarta.servlet.http.HttpServletResponse response, String forward, String msgType, String msgStr, UserInfo userInfo)
      页面返回值判断,主要是处理当通过ajax请求登陆验证时用
      参数:
      request - HttpServletRequest
      response - HttpServletResponse
      forward - String
      msgType - String
      msgStr - String
      userInfo - UserInfo
    • isUserExist

      protected boolean isUserExist(SHServletContext context, DataCenter dc, String userId) throws Exception
      判定用户名是否存在
      参数:
      userId - String 用户名
      返回:
      boolean true存在;false不存在
      抛出:
      Exception
    • isAuthentication

      protected boolean isAuthentication(SHServletContext context) throws Exception
      判断用户名和密码是否正确,不正确则开始设置记数器;
      参数:
      context - SHServletContext
      返回:
      true正确,false不正确
      抛出:
      Exception
    • isAuth

      public int isAuth()
      从类复制的说明: SHServletBase
      是否进行登陆权限验证
      覆盖:
      isAuth 在类中 SHServletBase
      返回:
      AUTH_LOGIN | AUTH_LOGIN_IGNORE