org.jasig.portal.security.provider
Class BasicLocalConnectionContext
java.lang.Object
org.jasig.portal.security.LocalConnectionContext
org.jasig.portal.security.provider.BasicLocalConnectionContext
public class BasicLocalConnectionContext
- extends LocalConnectionContext
BasicLocalConnectionContext implements HTTP Basic Authentication as a
LocalConnectionContext. Connections are provided as Objects:
they may be URL, LDAP, database connections, etc.
In order to use this class you should define two publish time parameters for
your channel: remote.username and remote.password.
The username and password default to "tomcat" if you don't set them.
- Version:
- $Revision: 19776 $ $Date: 2010-01-14 16:17:21 -0600 (Thu, 14 Jan 2010) $
- Author:
- Stephen Barrett, smb1@cornell.edu
|
Method Summary |
void |
init(ChannelStaticData sd)
Constructs the username/password combination from the parameters
set at publish time. |
void |
sendLocalData(Object connection,
ChannelRuntimeData rd)
Sets the headers so that the connection will authenticate using
HTTP Basic Authentication using the username and password passed
set at publish time. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
CHANPARAMUSERNAME
protected static final String CHANPARAMUSERNAME
- See Also:
- Constant Field Values
CHANPARAMPASSWORD
protected static final String CHANPARAMPASSWORD
- See Also:
- Constant Field Values
AUTHORIZATIONHDR
protected static final String AUTHORIZATIONHDR
- See Also:
- Constant Field Values
AUTHORIZATIONTYPE
protected static final String AUTHORIZATIONTYPE
- See Also:
- Constant Field Values
USERNAMEANDPWDMASK
protected static final String USERNAMEANDPWDMASK
- See Also:
- Constant Field Values
BasicLocalConnectionContext
public BasicLocalConnectionContext()
init
public void init(ChannelStaticData sd)
- Constructs the username/password combination from the parameters
set at publish time.
- Overrides:
init in class LocalConnectionContext
- Parameters:
sd - The calling channel's ChannelStaticData.
sendLocalData
public void sendLocalData(Object connection,
ChannelRuntimeData rd)
- Sets the headers so that the connection will authenticate using
HTTP Basic Authentication using the username and password passed
set at publish time.
- Overrides:
sendLocalData in class LocalConnectionContext
- Parameters:
connection - Must be an instance of HttpURLConnectionrd - The calling channel's ChannelRuntimeData.
Copyright © 2010 Jasig. All Rights Reserved.