You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Jonas Lundberg <my...@gmail.com> on 2006/01/24 16:38:54 UTC

Re: Obtain authentication data inside and outside of protected pipeline?

I might be wrong, but I think that authentication data is only
available inside  <map:act type="auth-protect"></map:act>

Regards
Hans

On 1/24/06, Derek Hohls <DH...@csir.co.za> wrote:
> I am trying to obtain authentication data inside and outside of protected pipeline.
>
> INSIDE the pipeline I have :
>
> <map:match pattern="docs/show-**">
>   <map:act type="auth-protect">
>     <map:parameter name="handler" value="myhandler"/>
>
>   <map:match pattern="docs/show-protected">
>       <map:generate src="docs/protected.xml"/>
>       <map:transform type="session"/>
>       <map:transform src="stylesheets/page.xsl">
>      <map:parameter name="userid" value="{session-context:authentication/authentication/ID}"/>
>    </map:transform>
>       <map:serialize/>
>   </map:match>
>
> And this works OK (I can obtain "userid").
>
> OUTSIDE the pipeline I have :
>
>    <map:match pattern="docs/*.htm">
>      <map:generate src="docs/{1}.xml"/>
>    <map:call resource="page2html"/>
>    <map:serialize type="html"/>
>    </map:match>
>
> and in the resource section:
>
>  <map:resources>
>    <map:resource name="page2html">
>      <map:transform src="stylesheets/page.xsl">
>        <map:parameter name="userid"  value="{ID}"/>
>     <!--  HAVE ALSO TRIED
>     <map:parameter name="userid"  value="{session-context:/authentication/authentication/ID}"/>
>       <map:parameter name="userid"  value="{session-attr:ID}"/>
>     -->
>      </map:transform>
>    </map:resource>
>  </map:resources>
>
>  But this does not work after the user has logged in?
>
>  What is the correct method for obtaining authentication data
>  outside of a protected pipeline?
>
>  Thanks
>  Derek
>
>
>
> --
> This message is subject to the CSIR's copyright, terms and conditions and
> e-mail legal notice. Views expressed herein do not necessarily represent the
> views of the CSIR.
>
> CSIR E-mail Legal Notice
> http://mail.csir.co.za/CSIR_eMail_Legal_Notice.html
>
> CSIR Copyright, Terms and Conditions
> http://mail.csir.co.za/CSIR_Copyright.html
>
> For electronic copies of the CSIR Copyright, Terms and Conditions and the CSIR
> Legal Notice send a blank message with REQUEST LEGAL in the subject line to
> HelpDesk@csir.co.za.
>
>
> This message has been scanned for viruses and dangerous content by MailScanner,
> and is believed to be clean.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
> For additional commands, e-mail: users-help@cocoon.apache.org
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org