Skip to main content



      Home
Home » Eclipse Projects » Remote Application Platform (RAP) » FORM based authentication + static content
FORM based authentication + static content [message #635500] Wed, 27 October 2010 03:07 Go to next message
Eclipse UserFriend
Hi,
I'd like to have a FORM based authentication in my RAP app. So in web.xml I add correspond section. But I'v got a 404 error:
"The requested resource /login.html is not available". Seems like container can't find login.html (I put login.html next to WEB-INF).
The only way it works is to change alias from static resource /login.html to my servlet which defined in web.xml and which output this login.html.
From:
<form-login-config>
	<form-login-page>/login.html</form-login-page>
</form-login-config>

To:
<form-login-config>
	<form-login-page>/ShowLoginPageServlet</form-login-page>
</form-login-config>

But if I remove equinox bridge servlet from web.xml then container can find login.html.
P.S. I can't use a plain (RAP) dialog to query user name and password coz users can save their user name and password in browser (for example with opera wand).
Is it possible to use "normal" static contents in container with RAP app without addition servlets or something else?

[Updated on: Wed, 27 October 2010 03:11] by Moderator

Re: FORM based authentication + static content [message #635828 is a reply to message #635500] Thu, 28 October 2010 05:32 Go to previous messageGo to next message
Eclipse UserFriend
Hi,

since the Equinox bridge servlet is usually mapped to /* in your web.xml,
it takes precedence over any static content in /. So any content
delivered from this web app has to come from Equinox.

You can also register a static resource with Equinox like this:

<extension
point="org.eclipse.equinox.http.registry.resources">
<resource
alias="/login"
base-name="/html/login.html">
</resource>
</extension>

Regards, Ralf

--
Ralf Sternberg

Need professional support for RAP and RCP?
http://www.eclipsesource.com/support/

Twitter: http://twitter.com/eclipsesource
Blog: http://www.eclipsesource.com/blogs/
Re: FORM based authentication + static content [message #635858 is a reply to message #635828] Thu, 28 October 2010 07:41 Go to previous message
Eclipse UserFriend
Ok, thx for your reply. I find a solution (don't check yet) here:
http:// angelozerr.wordpress.com/2010/09/08/osgi-equinox-in-a-servle t-container-step4/
Previous Topic:Console plugin
Next Topic:Client Time Zone
Goto Forum:
  


Current Time: Sun Jul 06 18:49:43 EDT 2025

Powered by FUDForum. Page generated in 0.03954 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top