You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Andreas Toom <an...@comitnet.com> on 2005/04/01 08:43:37 UTC
+ SSL ( + foreign context )
Hello,
I have 2 questions (See below for details)
1, Does <bean:include> work with SSL? if so, how?
2, Does JSTL <c:import> work with Struts actions?
Yesterday after some months of developing on a Struts application it was
time to enable SSL. Enabling tomcat with SSL support was no problem and
it looked like it would be a sweet ride but out of nowhere this
exception pops up:
Exception opening resource
https://localhost/fragments/fragment_login.jsp:
javax.net.ssl.SSLHandshakeException:
sun.security.validator.ValidatorException: No trusted certificate found
The fragment is included with:
<bean:include id="login" page="/fragments/fragment_login.jsp" />
and then
<bean:write name="login" filter="false"/>
Includes works fine without SSL. SSL works and I can render the fragment
jsp alone without any problems, in fact the whole Struts app works fine
with SSL as long as I don't use <bean:include>.
After some googling I find this mailinglist post:
http://www.newsarch.com/archive/mailinglist/jakarta/struts/user/msg29088.html
with a similar error but no solution.
Alternative solutions:
I try <jsp:include> and it works fine, but the problem is that I have
another app which will include the login fragment aswell so I need
something that can access a foreign context (App B will access fragments
from the context of App A) I try JSTL c:import with
href="/fragments/fragment_login.jsp" and context="/" which in my mind
would lead to a http request from App B to App A and the inclusion of
the response as a String, but instead I get a action mapping error
saying action /login cannot be found, well of course since the action
/login is not defined in App B only in App A.
How does the <c:import> work? shouldn't <c:import> return the content in
HTML not in jsp-code (?) for App B to compile in the App B context?
So this is what it all sums up to:
<bean:include> cannot include content over SSL ?,
<jsp:include> and JSTL <c:import> can both include content over SSL,
JSTL <c:import> cannot import content with Struts action references from
antoher context???
Any ideas would be really appreciated.
/Andreas
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org