Class ExternalAuthHelper
- java.lang.Object
-
- edu.cornell.mannlib.vitro.webapp.controller.authenticate.ExternalAuthHelper
-
- Direct Known Subclasses:
FakeExternalAuthController.FakeExternalAuthHelper
public class ExternalAuthHelper extends Object
Capture the properties used by the External Authorization system, and use them to assist in the process. The first time this bean is requested, it is created from the configuration properties and cached in the session. After that, the cached version is used.
-
-
Field Summary
Fields Modifier and Type Field Description static StringPROPERTY_EXTERNAL_AUTH_ID_HEADERThis configuration property says which HTTP header holds the auth ID.
-
Constructor Summary
Constructors Modifier Constructor Description protectedExternalAuthHelper(String externalAuthServerUrl, String externalAuthHeaderName)It would be private, but we want to allow subclasses for faking.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description StringbuildExternalAuthRedirectUrl(String returnUrl)StringgetExternalAuthId(javax.servlet.http.HttpServletRequest request)static ExternalAuthHelpergetHelper(javax.servlet.ServletRequest request)Get the bean from the servlet context.protected static voidsetBean(javax.servlet.ServletContext context, ExternalAuthHelper bean)It would be private, but we want to allow calls for faking.StringtoString()
-
-
-
Field Detail
-
PROPERTY_EXTERNAL_AUTH_ID_HEADER
public static final String PROPERTY_EXTERNAL_AUTH_ID_HEADER
This configuration property says which HTTP header holds the auth ID.- See Also:
- Constant Field Values
-
-
Method Detail
-
getHelper
public static ExternalAuthHelper getHelper(javax.servlet.ServletRequest request)
Get the bean from the servlet context. If there is no bean, create one. Never returns null.
-
setBean
protected static void setBean(javax.servlet.ServletContext context, ExternalAuthHelper bean)It would be private, but we want to allow calls for faking.
-
getExternalAuthId
public String getExternalAuthId(javax.servlet.http.HttpServletRequest request)
-
-