Thanks for the advice! I've solved the problems by creating another publication in the tomcat directory which contains the jsp files. To access my main publication, one first loads the jsp file of the "dummy" publication, which forwards the Windows user id to the Lenya login module. In this way it is possible to target the jcifs filter to the dummy publication, thus avoiding "disturbing" the main Lenya publication.
After some alterings of the login module, "manual" creation of users in Lenya with usernames from the AD, I've succeded to create a kind of "ad hoc" SSO-solution for Lenya. It is not pretty, but it works... Thorsten Scherler-3 wrote: > > On Mon, 2008-06-02 at 03:01 -0700, jazzhazze wrote: >> Thanks for the reply. >> I would like to implement this jsp-page (or at least a modification of >> it) >> to solve my "old problem" with the authentication to certain pages of my >> intranet-site. I want to use the url that is passed as a key to grant >> access >> to certain pages of my publication. > > As I understand it you are trying to "just" set some request headers, > right? To load a page before a page is NOT what you are not want nor > should do in any apps. > > You problem can be solved best as an Action. > http://cocoon.apache.org/2.1/userdocs/concepts/actions.html > > Use the action from > http://cocoon.apache.org/2.1/userdocs/concepts/actions.html#Creating+the > +Action as basis and add your code there. The part you need is setting > the request headers and if auth fails the action should return null > otherwise a empty map (not null !!!). > > Then in your pub sitemap it would be something like: > <map:match pattern="**"> > <map:act type="AuthAction"> > <map:generate src="{1}"/> > <map:serialize/> > </map:act> > <map:generate src="SomeErrorPage"/> > <map:serialize/> > </map:match> > > If you return an empty map (not null) the code inside the action is used > and if you return null the other part. > > In any case I personally would implement this with Apache http and the > mod_auth (and a like). > http://httpd.apache.org/docs/2.0/mod/mod_auth.html > > HTH > > salu2 > -- > Thorsten Scherler thorsten.at.apache.org > Open Source Java consulting, training and solutions > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > > -- View this message in context: http://www.nabble.com/How-to-load-a-JSP-page-%22before%22-loading-...-live-index.html-tp17552620p17866236.html Sent from the Lenya - Users mailing list archive at Nabble.com. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
