Package edu.yale.its.tp.cas.client
Class ServiceTicketValidator
java.lang.Object
edu.yale.its.tp.cas.client.ServiceTicketValidator
- Direct Known Subclasses:
ProxyTicketValidator
Validates STs and optionally retrieves PGT IOUs. Designed with a bean-like interface for simplicity and generality.
-
Nested Class Summary
Nested Classes -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidclear()Clears internally manufactured state.Gets the CAS validation URL to use when validating tickets and retrieving PGT IOUs.Returns CAS's error code if authentication failed.Returns an error message if CAS authentication failed.Returns the PGT IOU returned by CAS.Gets the callback URL, owned logically by the calling service, to receive the PGTid/PGTiou mapping.Retrieves CAS's entire response, if authentication was succsesful.getUser()Returns the strongly authenticated username.booleanReturnstrueif the most recent authentication attempted succeeded,falseotherwise.protected DefaultHandlervoidSets the CAS validation URL to use when validating tickets and retrieving PGT IOUs.voidSets the callback URL, owned logically by the calling service, to receive the PGTid/PGTiou mapping.voidsetRenew(boolean b) Sets the "renew" flag on authentication.voidsetService(String x) Sets the service to use when validating.voidSets the ST to validate.voidvalidate()
-
Field Details
-
casValidateUrl
-
proxyCallbackUrl
-
st
-
service
-
pgtIou
-
user
-
errorCode
-
errorMessage
-
entireResponse
-
renew
protected boolean renew -
attemptedAuthentication
protected boolean attemptedAuthentication -
successfulAuthentication
protected boolean successfulAuthentication
-
-
Constructor Details
-
ServiceTicketValidator
public ServiceTicketValidator()
-
-
Method Details
-
setCasValidateUrl
Sets the CAS validation URL to use when validating tickets and retrieving PGT IOUs. -
getCasValidateUrl
Gets the CAS validation URL to use when validating tickets and retrieving PGT IOUs. -
setProxyCallbackUrl
Sets the callback URL, owned logically by the calling service, to receive the PGTid/PGTiou mapping. -
setRenew
public void setRenew(boolean b) Sets the "renew" flag on authentication. When set to "true", authentication will only succeed if this was an initial login (forced by the "renew" flag being set on login). -
getProxyCallbackUrl
Gets the callback URL, owned logically by the calling service, to receive the PGTid/PGTiou mapping. -
setServiceTicket
Sets the ST to validate. -
setService
Sets the service to use when validating. -
getUser
Returns the strongly authenticated username. -
getPgtIou
Returns the PGT IOU returned by CAS. -
isAuthenticationSuccesful
public boolean isAuthenticationSuccesful()Returnstrueif the most recent authentication attempted succeeded,falseotherwise. -
getErrorMessage
Returns an error message if CAS authentication failed. -
getErrorCode
Returns CAS's error code if authentication failed. -
getResponse
Retrieves CAS's entire response, if authentication was succsesful. -
validate
-
newHandler
-
clear
protected void clear()Clears internally manufactured state.
-