Package com.xpn.xwiki.user.impl.xwiki
Class AbstractXWikiAuthService
- java.lang.Object
-
- com.xpn.xwiki.user.impl.xwiki.AbstractXWikiAuthService
-
- All Implemented Interfaces:
XWikiAuthService
- Direct Known Subclasses:
XWikiAuthServiceImpl
public abstract class AbstractXWikiAuthService extends Object implements XWikiAuthService
Common methods useful to all Authentication services implementations.- Version:
- $Id: 336c0f8e256582abc02e3c2cc4b92c1d926df2bf $
-
-
Constructor Summary
Constructors Constructor Description AbstractXWikiAuthService()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected Principal
authenticateSuperAdmin(String password, XWikiContext context)
protected boolean
isSuperAdmin(String username)
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.xpn.xwiki.user.api.XWikiAuthService
authenticate, checkAuth, checkAuth, showLogin
-
-
-
-
Method Detail
-
isSuperAdmin
protected boolean isSuperAdmin(String username)
- Parameters:
username
- the username to check for superadmin access. Examples: "xwiki:XWiki.superadmin", "XWiki.superAdmin", "superadmin", etc- Returns:
- true if the username is that of the superadmin (whatever the case) or false otherwise
-
authenticateSuperAdmin
protected Principal authenticateSuperAdmin(String password, XWikiContext context)
- Parameters:
password
- the superadmin password to check against the superadmin password located in XWiki's config filecontext
- the XWiki context object, allowing access to XWiki's config- Returns:
- a null Principal is the user hasn't been validated as Superadmin or a Super Admin Principal otherwise
-
-