cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Peter Kröpfl <pe...@groebi.com>
Subject authentication fw and jx
Date Tue, 19 Apr 2005 14:43:48 GMT
Hi.

I am trying to do authentication against a database using the auth.fw. of cocoon
like this.

Is it possible to use the auth.fw and flow and jx like this?

sitemap:
<map:match pattern="authenticate">
 <map:call function="login" />
 <map:generate src="pages/jx/login.jx" />
 <map:transform type="jx" />
 <map:transform src="xsl/authenticate.xsl">
  <map:parameter name="use-request-parameters" value="true"/>
 </map:transform>
 <map:serialize />
</map>

jx: 
<authentication>
 <users>
  <user>
   <name>cocoon</name>
  </user>
  <user>
   <name>${cocoon.session.ID}</name>
  </user>
 </users>
</authentication>

flow: 
function login()
  
  // do some db stuff here.
  // if everything OK save user_id to session
  cocoon.session.setAttribute("ID", "guest");
}


If I comment out "<map:call function="login">" and use "cocoon" as username
everything works fine. If I call the function login it seems that the rest of
the matcher is not executed.


thanks, peter


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


Mime
View raw message