com.silverpeas.jcrutil.security.impl
Class SilverpeasBasicCredentialsProvider
java.lang.Object
com.silverpeas.jcrutil.security.impl.SilverpeasBasicCredentialsProvider
- All Implemented Interfaces:
- org.apache.jackrabbit.server.CredentialsProvider
Deprecated. replaced by WebDavCredentialsProvider class.
@Deprecated
public class SilverpeasBasicCredentialsProvider
- extends Object
- implements org.apache.jackrabbit.server.CredentialsProvider
This code is a derivative of the org.apache.jackrabbit.server.BasicCredentialsProvider form
Apache Jackrabbit whic is under Apache 2.0 License.
- Author:
- ehugonnet
Method Summary |
javax.jcr.Credentials |
getCredentials(javax.servlet.http.HttpServletRequest request)
Deprecated. Build a Credentials object for the given authorization header. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
SilverpeasBasicCredentialsProvider
public SilverpeasBasicCredentialsProvider(String defaultHeaderValue)
- Deprecated.
- Constructs a new BasicCredentialsProvider with the given default value {
- Parameters:
defaultHeaderValue
- - See Also:
for details.
getCredentials
public javax.jcr.Credentials getCredentials(javax.servlet.http.HttpServletRequest request)
throws javax.jcr.LoginException,
javax.servlet.ServletException
- Deprecated.
- Build a
Credentials
object for the given authorization header. The creds
may be used to login to the repository. If the specified header string is null
the
behaviour depends on the defaultHeaderValue
field:
- if this field is
null
, a LoginException is thrown. This is suiteable for
clients (eg. webdav clients) for with sending a proper authorization header is not possible, if
the server never send a 401.
- if this an empty string, null-credentials are returned, thus forcing an null login on the
repository
- if this field has a 'user:password' value, the respective simple credentials are generated.
If the request header is present but cannot be parsed a ServletException
is
thrown.
- Specified by:
getCredentials
in interface org.apache.jackrabbit.server.CredentialsProvider
- Parameters:
request
- the servlet request
- Returns:
- credentials or
null
.
- Throws:
javax.servlet.ServletException
- If the Authorization header cannot be decoded.
javax.jcr.LoginException
- if no suitable auth header and missing-auth-mapping is not present
Copyright © 2016 Silverpeas. All Rights Reserved.