public class XWikiAuthServiceImpl extends AbstractXWikiAuthService
XWikiAuthService
.Modifier and Type | Field and Description |
---|---|
protected Map<String,XWikiAuthenticator> |
authenticators
Each wiki has its own authenticator.
|
Constructor and Description |
---|
XWikiAuthServiceImpl() |
Modifier and Type | Method and Description |
---|---|
Principal |
authenticate(String username,
String password,
XWikiContext context) |
XWikiUser |
checkAuth(String username,
String password,
String rememberme,
XWikiContext context)
Method to authenticate and set the cookie from a username and password passed as parameters
|
XWikiUser |
checkAuth(XWikiContext context) |
protected boolean |
checkPassword(String username,
String password,
XWikiContext context) |
protected String |
createUser(String user,
XWikiContext context) |
protected String |
findUser(String username,
XWikiContext context) |
protected XWikiAuthenticator |
getAuthenticator(XWikiContext context) |
protected String |
getParam(String name,
XWikiContext context) |
void |
showLogin(XWikiContext context) |
protected String |
stripContextPathFromURL(URL url,
XWikiContext context)
The authentication library we are using (SecurityFilter) requires that its URLs do not contain the context path,
in order to be usable with RequestDispatcher.forward.
|
authenticateSuperAdmin, isSuperAdmin
protected Map<String,XWikiAuthenticator> authenticators
protected XWikiAuthenticator getAuthenticator(XWikiContext context) throws XWikiException
XWikiException
public XWikiUser checkAuth(XWikiContext context) throws XWikiException
XWikiException
public XWikiUser checkAuth(String username, String password, String rememberme, XWikiContext context) throws XWikiException
username
- the user name for the user to authenticatepassword
- the password of the user to authenticatecontext
- the XWiki context objectXWikiException
- in case of authentication errorpublic void showLogin(XWikiContext context) throws XWikiException
XWikiException
public Principal authenticate(String username, String password, XWikiContext context) throws XWikiException
XWikiException
protected String findUser(String username, XWikiContext context) throws XWikiException
XWikiException
protected boolean checkPassword(String username, String password, XWikiContext context) throws XWikiException
XWikiException
protected String getParam(String name, XWikiContext context)
protected String createUser(String user, XWikiContext context) throws XWikiException
XWikiException
protected String stripContextPathFromURL(URL url, XWikiContext context)
url
- The URL to process.context
- The ubiquitous XWiki request context.String
representation of the contextpath-free URL.Copyright © 2004–2021 XWiki. All rights reserved.