Package sonia.scm.security
Class Tokens
java.lang.Object
sonia.scm.security.Tokens
Create tokens for security reasons.
- Since:
- 1.21
-
Method Summary
Modifier and TypeMethodDescriptionstatic org.apache.shiro.authc.AuthenticationTokencreateAuthenticationToken(jakarta.servlet.http.HttpServletRequest request, String username, String password) Build anAuthenticationTokenfor use withSubject.login(org.apache.shiro.authc.AuthenticationToken).
-
Method Details
-
createAuthenticationToken
public static org.apache.shiro.authc.AuthenticationToken createAuthenticationToken(jakarta.servlet.http.HttpServletRequest request, String username, String password) Build anAuthenticationTokenfor use withSubject.login(org.apache.shiro.authc.AuthenticationToken).- Parameters:
request- servlet requestusername- username of the user to authenticatepassword- password of the user to authenticate- Returns:
- authentication token
-