Class AuthenticationFilter

java.lang.Object
sk.iway.iwcm.system.ntlm.AuthenticationFilter
All Implemented Interfaces:
jakarta.servlet.Filter

public class AuthenticationFilter extends Object implements jakarta.servlet.Filter
  • Constructor Details

    • AuthenticationFilter

      public AuthenticationFilter()
  • Method Details

    • init

      public void init(jakarta.servlet.FilterConfig filterConfig) throws jakarta.servlet.ServletException
      Specified by:
      init in interface jakarta.servlet.Filter
      Throws:
      jakarta.servlet.ServletException
    • destroy

      public void destroy()
      Specified by:
      destroy in interface jakarta.servlet.Filter
    • doFilter

      public void doFilter(jakarta.servlet.ServletRequest request, jakarta.servlet.ServletResponse response, jakarta.servlet.FilterChain chain) throws IOException, jakarta.servlet.ServletException
      This method simply calls negotiate( req, resp, false ) and then chain.doFilter. You can override and call negotiate manually to achive a variety of different behavior.
      Specified by:
      doFilter in interface jakarta.servlet.Filter
      Throws:
      IOException
      jakarta.servlet.ServletException
    • negotiateIIS

      public static Principal negotiateIIS(jakarta.servlet.http.HttpServletRequest req, jakarta.servlet.http.HttpServletResponse resp, boolean skipAuthentication) throws IOException, jakarta.servlet.ServletException
      Negotiate user from request.getUserPrincipal(), check for correct domainName from NTLMiisTrustedDomains
      Parameters:
      req -
      resp -
      skipAuthentication -
      Returns:
      Throws:
      IOException
      jakarta.servlet.ServletException
    • getLdapPassword

      public static String getLdapPassword()
      Returns:
      Returns the ldapPassword.
    • getLdapProvider

      public static String getLdapProvider()
      Returns:
      Returns the ldapProvider.
    • getLdapUsername

      public static String getLdapUsername()
      Returns:
      Returns the ldapUsername.
    • getForbiddenURL

      public static String getForbiddenURL()
      Returns:
      Returns the forbiddenURL.
    • weTrustIIS

      public static boolean weTrustIIS()
      ak je vo web.xml zadany config parameter iis.trustIIS, beriem primarne inak beriem co je zadane vo WJ konf. premennej authenticationTrustIIS
      Returns:
    • getDomainController

      public static String getDomainController()