Class CookieAuthenticationProvider

java.lang.Object
io.jmix.webdavrest.security.CookieAuthenticationProvider
All Implemented Interfaces:
org.springframework.security.authentication.AuthenticationProvider

public class CookieAuthenticationProvider extends Object implements org.springframework.security.authentication.AuthenticationProvider
Is used for 'cookie' authentication method. This Authentication provider tries to authenticate user by 2 tokens:
  • URL-token: one-time token included directly to URL generated by WebdavEndPointLinkController. Handling request with such valid token generates Cookie-token. When it's invalidated, but still used in URL.
  • Cookie-token: secured persistent cookie used as main auth token during further WebDAV requests
  • Field Details

  • Constructor Details

  • Method Details

    • authenticate

      public org.springframework.security.core.Authentication authenticate(org.springframework.security.core.Authentication authentication) throws org.springframework.security.core.AuthenticationException
      Specified by:
      authenticate in interface org.springframework.security.authentication.AuthenticationProvider
      Throws:
      org.springframework.security.core.AuthenticationException
    • supports

      public boolean supports(Class<?> authentication)
      Specified by:
      supports in interface org.springframework.security.authentication.AuthenticationProvider
    • isUrlTokenValid

      protected boolean isUrlTokenValid(String token)
    • isCookieTokenValid

      protected boolean isCookieTokenValid(String token)