You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Sami Dalouche <sk...@free.fr> on 2007/10/07 19:49:50 UTC

Re: Has anyone developed a web app using struts 2 and agegi security framework?

Hi,

I guess that by "integrating acegi and struts 2", you mean, "integrating
acegi URL security with struts 2".

So, here are some tips...

1] Configure Acegi however you would do it using pure JSP / servlets
2] Create an interceptor using the instructions given here
http://struts.apache.org/2.0.9/docs/can-we-use-acegi-security-with-the-framework.html
3] Additionally, if you use freemarker and you cannot make your action
implement the AuthzAware interface (or if you want to use some Acegi
code inside Sitemesh, for instance), you can use the JSP Taglib provided
by sitemesh
<#assign authz=JspTaglibs["/WEB-INF/tld/authz.tld"] />
<@authz.authorize ifNotGranted="ROLE_USER">
...
</...@authz.authorize>

And that should be enough to get acegi working with struts2..

Regards,
Sami Dalouche

Le dimanche 07 octobre 2007 à 15:12 +0700, Tuyen Dinh Van a écrit :
> I am now developing my own management suite using struts 2, and I also
> intend to use acegi for security, but very few document available for such
> integration.
> 
> Has any one successfully integrated the acegi framework into struts 2?
> Any suggestion is appreciated.
> 
> Thanks


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org