On 13-09-10 09:14 AM, Trenton D. Adams wrote:
On 13-09-09 03:57 PM, Trenton D. Adams wrote:
Hi Guys,
I do not understand this spring web flow stuff very well, and there
doesn't appear to be a good concise document on getting started with it.
There's just loads of a documentation that would take a very long time
to read. Does anyone know of a good getting started guide; like more of
a reference, than a monolithic document?
It would also be nice to know if there's some concise documentation on
CAS attributes that are available for use, and which scope they get put
in. That may be my biggest issue actually, not knowing what attributes
CAS uses, and in which scope/objects they are.
At the moment, I'm attempting to make sure the user gets *authenticated*
and the actual cookie is generated, followed by display of a custom
page. That page will then link to /cas/login?service=, so that the user
can continue on to the service they wanted to use, or go on to the
password service. I do manage to redirect to a custom JSP page, using
the following end-state, but CAS does not remain authenticated. How can
I fix that problem? I'm assuming I can add something in my end-state,
or possibly prior to that, to force the cookie to be sent to the browser?
<end-state id="showAUExpiryWarningView" view="auExpiryWarningView">
<on-entry>
<set name="requestScope.originalUrl"
value="flowScope.service.id" />
<set name="requestScope.passwordUrl"
value="performAUOnLoginChecksAction.getBaseURLOnFail()" />
</on-entry>
</end-state>
I finally managed to get it working. But, then it blew up when I don't
pass a service. So, I instead passed the flowScope.service as an
attribute in the requestScope, so that I could access the id using JSP
EL (${service.id}), which does not throw errors on null pointers.
Note: there is a reference to flowScope.service.id elsewhere in the
default login-webflow.xml. I can't imagine that works either.
I'd still like to see the CAS spring web flow attribute reference.
Oh, in case anyone else has this trouble, I basically ended up with this...
<action-state id="performAUOnLoginChecks">
<evaluate expression="performAUOnLoginChecksAction" />
<transition on="success" to="sendTicketGrantingTicket" />
<transition on="expiryWarning" to="prepExpiryWarningView" />
<transition on="error" to="generateLoginTicket" />
</action-state>
<action-state id="prepExpiryWarningView">
<evaluate expression="sendTicketGrantingTicketAction" />
<transition on="success" to="showAUExpiryWarningView" />
<transition on="error" to="generateLoginTicket" />
</action-state>
<!--
The "showAUExpiryWarningView" end state is the end state for when
the user's
password is going to expire. It delegates to a view defined in
default_views.properties that displays a message, and allows the
user to
either change their password now, or continue to the service they
wanted to
access.
-->
<end-state id="showAUExpiryWarningView" view="auExpiryWarningView">
<on-entry>
<set name="requestScope.originalService" value="flowScope.service" />
<set name="requestScope.passwordUrl"
value="performAUOnLoginChecksAction.getBaseURLOnFail()" />
</on-entry>
</end-state>
--
Trenton D. Adams
Senior Systems Analyst/Web Software Developer
Navy Penguins at your service!
Athabasca University
(780) 675-6195
:wq!
--
This communication is intended for the use of the recipient to whom it
is addressed, and may contain confidential, personal, and or privileged
information. Please contact us immediately if you are not the intended
recipient of this communication, and do not copy, distribute, or take
action relying on it. Any communications received in error, or
subsequent reply, should be deleted or destroyed.
---
--
You are currently subscribed to [email protected] as:
[email protected]
To unsubscribe, change settings or access archives, see
http://www.ja-sig.org/wiki/display/JSG/cas-user