public class TokenUtil
extends java.lang.Object
TokenUtil class provides utility methods to generate login-tokens| Modifier and Type | Method and Description |
|---|---|
static AuthenticationInfo |
createCredentials(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response,
SlingRepository repository,
java.lang.String userId,
boolean httpOnly)
Deprecated.
Generates a login-token for a given userId, sets the token-cookie, and returns an
AuthenticationInfo object suited for the TokenAuthenticationHandler |
public static AuthenticationInfo createCredentials(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, SlingRepository repository, java.lang.String userId, boolean httpOnly) throws RepositoryException
AuthenticationInfo object suited for the TokenAuthenticationHandlerrequest - The HttpServletRequest associated with this authentication attemptresponse - The HttpServletResponse on which to set the cookierepository - The SlingRepository to authenticate againstuserId - The ID of the authenticating userhttpOnly - Whether or not to set the HttpOnly attribute on the token cookieAUTH_TYPERepositoryExceptionCopyright © 2010 - 2023 Adobe. All Rights Reserved