You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Pe...@mediacenter.nl on 2005/05/02 23:16:28 UTC
Betr.: Re: Betr.: Re: Betr.: Re: Betr.: authentication-fw
Andre Juffer <aj...@sun3.oulu.fi> wrote on 02-05-2005 22:36:53:
> Peter.Urbanus@mediacenter.nl wrote:
> >
> >
> > In particular, what happens if you add the extra match <map:match
> > type="request-parameter" pattern="userid"> into your simplified
> > "authenticate" pipeline above?
>
> <map:match pattern="authenticate">
> <map:match type="request-parameter" pattern="userid">
> <map:generate src="/tmp/authenticate.xml" />
> <map:serialize type="xml" />
> </map:match>
> </map:match>
>
>
> Authentication works. But the same file is being used of course
> (/tmp/authenticate.xml), so it should work.
Agreed. I just wanted to exclude the possibility that this match didn't
"match".
And what happens if you add whitespace to your /tmp/authenticate.xml? In my
setup, I can add all the whitespace I like and it still works. So, assuming
it's not the whitespace, we have two pipelines
<map:match pattern="authenticate.xxx">
<map:match type="request-parameter" pattern="userid">
<map:generate src="/tmp/authenticate.xml" />
<map:serialize type="xml" />
</map:match>
</map:match>
and
<map:match pattern="authenticate.xxx">
<map:match type="request-parameter" pattern="userid">
<map:generate src="cocoon://persistence/get-party?email={1}" />
<map:transform src="docs/xsl/authenticate.xsl">
<map:parameter name="use-request-parameters" value="true" />
</map:transform>
<map:serialize type="xml" />
</map:match>
</map:match>
First one works, second one doesn't.
Time to look at authenticate.xsl then? I would like to have a look at it.
There is one other thing you could do: use the LogTransformer to see the
SAX events. like this:
<map:match pattern="authenticate.xxx">
<map:match type="request-parameter" pattern="userid">
<map:generate src="cocoon://persistence/get-party?email={1}" />
<map:transform src="docs/xsl/authenticate.xsl">
<map:parameter name="use-request-parameters" value="true" />
</map:transform>
<map:transform type="log">
<map:parameter name="logfile" value="authenticate.log"/>
<map:parameter name="append" value="yes"/>
</map:transform>
<map:serialize type="xml" />
</map:match>
</map:match>
Regards, Peter
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org