| java.lang.Object com.caucho.server.security.AbstractAuthenticator com.caucho.server.security.AbstractPasswordAuthenticator com.caucho.server.security.XmlAuthenticator
All known Subclasses: com.caucho.http.security.XmlAuthenticator,
XmlAuthenticator | public class XmlAuthenticator extends AbstractPasswordAuthenticator (Code) | | The XML authenticator reads a static file for authentication.
<authenticator url="xml:path=WEB-INF/users.xml"/>
The format of the static file is as follows:
<users>
<user name="h.potter" password="quidditch" roles="user,captain"/>
...
</users>
The authenticator can also be configured in the resin-web.xml:
<authenticator url="xml:password-digest=none">
<init>
<user name="Harry Potter" password="quidditch" roles="user,captain"/>
</init>
</authenticator>
|
Inner Class :public static class User | |
Method Summary | |
public void | addUser(User user) Adds a user from the configuration. | public Path | getPath() Gets the path to the XML file. | protected PasswordUser | getUser(String userName) | public synchronized void | init() Initialize the XML authenticator. | public synchronized void | reload() Reload the authenticator. | public void | setPath(Path path) Sets the path to the XML file. |
addUser | public void addUser(User user)(Code) | | Adds a user from the configuration.
<init user='Harry Potter:quidditch:user,webdav'/>
|
getPath | public Path getPath()(Code) | | Gets the path to the XML file.
|
reload | public synchronized void reload()(Code) | | Reload the authenticator.
|
setPath | public void setPath(Path path)(Code) | | Sets the path to the XML file.
|
Methods inherited from com.caucho.server.security.AbstractPasswordAuthenticator | protected String getDigestPassword(HttpServletRequest request, HttpServletResponse response, ServletContext application, String userName, String realm) throws ServletException(Code)(Java Doc) abstract protected PasswordUser getUser(String userName)(Code)(Java Doc) protected PasswordUser getUser(Principal principal)(Code)(Java Doc) public boolean isUserInRole(HttpServletRequest request, HttpServletResponse response, ServletContext application, Principal principal, String role) throws ServletException(Code)(Java Doc) protected Principal loginImpl(HttpServletRequest request, HttpServletResponse response, ServletContext application, String userName, String password) throws ServletException(Code)(Java Doc)
|
Methods inherited from com.caucho.server.security.AbstractAuthenticator | public void addRoleMapping(Principal principal, String role)(Code)(Java Doc) protected byte[] digest(String value) throws ServletException(Code)(Java Doc) protected String getDigestPassword(HttpServletRequest request, HttpServletResponse response, ServletContext application, String username, String realm) throws ServletException(Code)(Java Doc) protected byte[] getDigestSecret(HttpServletRequest request, HttpServletResponse response, ServletContext application, String username, String realm, String algorithm) throws ServletException(Code)(Java Doc) public boolean getLogoutOnSessionTimeout()(Code)(Java Doc) public PasswordDigest getPasswordDigest()(Code)(Java Doc) public String getPasswordDigest(HttpServletRequest request, HttpServletResponse response, ServletContext app, String user, String password) throws ServletException(Code)(Java Doc) public String getPasswordDigestAlgorithm()(Code)(Java Doc) public String getPasswordDigestRealm()(Code)(Java Doc) public int getPrincipalCacheSize()(Code)(Java Doc) public Principal getUserPrincipal(HttpServletRequest request, HttpServletResponse response, ServletContext application) throws ServletException(Code)(Java Doc) protected Principal getUserPrincipalImpl(HttpServletRequest request, ServletContext application) throws ServletException(Code)(Java Doc) public void init() throws ServletException(Code)(Java Doc) public boolean isUserInRole(HttpServletRequest request, HttpServletResponse response, ServletContext application, Principal user, String role) throws ServletException(Code)(Java Doc) public Principal login(HttpServletRequest request, HttpServletResponse response, ServletContext app, String user, String password) throws ServletException(Code)(Java Doc) public Principal loginDigest(HttpServletRequest request, HttpServletResponse response, ServletContext app, String user, String realm, String nonce, String uri, String qop, String nc, String cnonce, byte[] clientDigest) throws ServletException(Code)(Java Doc) public Principal loginDigestImpl(HttpServletRequest request, HttpServletResponse response, ServletContext app, String user, String realm, String nonce, String uri, String qop, String nc, String cnonce, byte[] clientDigest) throws ServletException(Code)(Java Doc) protected Principal loginImpl(HttpServletRequest request, HttpServletResponse response, ServletContext application, String user, String password) throws ServletException(Code)(Java Doc) public void logout(ServletContext application, HttpSession timeoutSession, String sessionId, Principal user) throws ServletException(Code)(Java Doc) public void logout(HttpServletRequest request, HttpServletResponse response, ServletContext application, Principal user) throws ServletException(Code)(Java Doc) public void logout(ServletContext application, String sessionId, Principal user) throws ServletException(Code)(Java Doc) public void setLogoutOnSessionTimeout(boolean logout)(Code)(Java Doc) public void setPasswordDigest(PasswordDigest digest)(Code)(Java Doc) public void setPasswordDigestAlgorithm(String digest)(Code)(Java Doc) public void setPasswordDigestRealm(String realm)(Code)(Java Doc) public void setPrincipalCacheSize(int size)(Code)(Java Doc) public void setSerializationHandle(Object handle)(Code)(Java Doc) protected byte[] stringToDigest(String digest)(Code)(Java Doc) public String toString()(Code)(Java Doc) public Object writeReplace()(Code)(Java Doc)
|
|
|