[jboss-user] [JBoss Seam] - Re: not redirecting to security_error.xhtml

efabiano do-not-reply at jboss.com
Mon May 14 13:03:56 EDT 2007


Hi Christian,

The complete stack trace is:

SEVERE: Error Rendering View[/Cor.xhtml]
  | org.jboss.seam.security.AuthorizationException: Authorization check failed for expression [#{s:hasPermission('corcontroller','selecionar', null)}]
  | 	at org.jboss.seam.security.Identity.checkRestriction(Identity.java:160)
  | 	at org.jboss.seam.interceptors.SecurityInterceptor.aroundInvoke(SecurityInterceptor.java:35)
  | 	at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:69)
  | 	at org.jboss.seam.interceptors.RemoveInterceptor.aroundInvoke(RemoveInterceptor.java:40)
  | 	at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:69)
  | 	at org.jboss.seam.interceptors.SynchronizationInterceptor.aroundInvoke(SynchronizationInterceptor.java:31)
  | 	at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:69)
  | 	at org.jboss.seam.intercept.RootInterceptor.invoke(RootInterceptor.java:103)
  | 	at org.jboss.seam.intercept.ClientSideInterceptor.invoke(ClientSideInterceptor.java:50)
  | 	at org.javassist.tmp.java.lang.Object_$$_javassist_101.selecionar(Object_$$_javassist_101.java)
  | 	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
  | 	at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
  | 	at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
  | 	at java.lang.reflect.Method.invoke(Unknown Source)
  | 	at org.jboss.seam.util.Reflections.invoke(Reflections.java:20)
  | 	at org.jboss.seam.util.Reflections.invokeAndWrap(Reflections.java:123)
  | 	at org.jboss.seam.Component.callComponentMethod(Component.java:1834)
  | 	at org.jboss.seam.Component.getInstanceFromFactory(Component.java:1696)
  | 	at org.jboss.seam.Component.getInstance(Component.java:1633)
  | 	at org.jboss.seam.Component.getInstance(Component.java:1610)
  | 	at org.jboss.seam.jsf.SeamVariableResolver.resolveVariable(SeamVariableResolver.java:53)
  | 	at org.apache.myfaces.config.LastVariableResolverInChain.resolveVariable(LastVariableResolverInChain.java:42)
  | 	at com.sun.facelets.el.LegacyELContext$LegacyELResolver.getValue(LegacyELContext.java:134)
  | 	at com.sun.el.parser.AstIdentifier.getValue(AstIdentifier.java:65)
  | 	at com.sun.el.ValueExpressionImpl.getValue(ValueExpressionImpl.java:192)
  | 	at com.sun.facelets.el.TagValueExpression.getValue(TagValueExpression.java:71)
  | 	at com.sun.el.parser.AstIdentifier.getValue(AstIdentifier.java:61)
  | 	at com.sun.el.ValueExpressionImpl.getValue(ValueExpressionImpl.java:192)
  | 	at com.sun.facelets.el.TagValueExpression.getValue(TagValueExpression.java:71)
  | 	at com.sun.el.parser.AstIdentifier.getValue(AstIdentifier.java:61)
  | 	at com.sun.el.parser.AstEmpty.getValue(AstEmpty.java:49)
  | 	at com.sun.el.ValueExpressionImpl.getValue(ValueExpressionImpl.java:192)
  | 	at com.sun.facelets.el.TagValueExpression.getValue(TagValueExpression.java:71)
  | 	at com.sun.facelets.el.LegacyValueBinding.getValue(LegacyValueBinding.java:56)
  | 	at javax.faces.component.UIComponentBase.isRendered(UIComponentBase.java:1075)
  | 	at org.ajax4jsf.framework.renderer.RendererBase.renderChild(RendererBase.java:246)
  | 	at org.ajax4jsf.framework.renderer.RendererBase.renderChildren(RendererBase.java:232)
  | 	at org.ajax4jsf.renderkit.html.AjaxOutputPanelRenderer.encodeChildren(AjaxOutputPanelRenderer.java:79)
  | 	at javax.faces.component.UIComponentBase.encodeChildren(UIComponentBase.java:524)
  | 	at org.ajax4jsf.framework.renderer.RendererBase.renderChild(RendererBase.java:252)
  | 	at org.ajax4jsf.framework.renderer.RendererBase.renderChildren(RendererBase.java:232)
  | 	at org.ajax4jsf.framework.renderer.RendererBase.renderChild(RendererBase.java:254)
  | 	at org.ajax4jsf.framework.renderer.RendererBase.renderChildren(RendererBase.java:232)
  | 	at org.ajax4jsf.framework.renderer.AjaxContainerRenderer.encodeChildren(AjaxContainerRenderer.java:100)
  | 	at javax.faces.component.UIComponentBase.encodeChildren(UIComponentBase.java:524)
  | 	at org.ajax4jsf.ajax.UIAjaxRegion.encodeChildren(UIAjaxRegion.java:119)
  | 	at com.sun.facelets.tag.jsf.ComponentSupport.encodeRecursive(ComponentSupport.java:244)
  | 	at com.sun.facelets.tag.jsf.ComponentSupport.encodeRecursive(ComponentSupport.java:249)
  | 	at com.sun.facelets.FaceletViewHandler.renderView(FaceletViewHandler.java:573)
  | 	at org.ajax4jsf.framework.ViewHandlerWrapper.renderView(ViewHandlerWrapper.java:108)
  | 	at org.ajax4jsf.framework.ajax.AjaxViewHandler.renderView(AjaxViewHandler.java:229)
  | 	at org.apache.myfaces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:384)
  | 	at javax.faces.webapp.FacesServlet.service(FacesServlet.java:138)
  | 	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
  | 	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
  | 	at org.ajax4jsf.framework.ajax.xmlfilter.BaseFilter.doFilter(BaseFilter.java:234)
  | 	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
  | 	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
  | 	at org.jboss.seam.web.ExceptionFilter.doFilter(ExceptionFilter.java:57)
  | 	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
  | 	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
  | 	at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:63)
  | 	at org.jboss.seam.web.RedirectFilter.doFilter(RedirectFilter.java:45)
  | 	at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:49)
  | 	at org.jboss.seam.web.ExceptionFilter.doFilter(ExceptionFilter.java:57)
  | 	at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:49)
  | 	at org.jboss.seam.web.MultipartFilter.doFilter(MultipartFilter.java:79)
  | 	at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:49)
  | 	at org.jboss.seam.web.SeamFilter.doFilter(SeamFilter.java:84)
  | 	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
  | 	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
  | 	at org.ajax4jsf.framework.ajax.xmlfilter.BaseXMLFilter.doXmlFilter(BaseXMLFilter.java:96)
  | 	at org.ajax4jsf.framework.ajax.xmlfilter.BaseFilter.doFilter(BaseFilter.java:220)
  | 	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
  | 	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
  | 	at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
  | 	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
  | 	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
  | 	at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
  | 	at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
  | 	at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:175)
  | 	at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:74)
  | 	at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
  | 	at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
  | 	at org.jboss.web.tomcat.tc5.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:156)
  | 	at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
  | 	at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
  | 	at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
  | 	at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
  | 	at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
  | 	at org.apache.tomcat.util.net.MasterSlaveWorkerThread.run(MasterSlaveWorkerThread.java:112)
  | 	at java.lang.Thread.run(Unknown Source)


This is what apears on my screen (where should be security_error.xhtml):

An Error Occurred:
  | Authorization check failed for expression [#{s:hasPermission('corcontroller','selecionar', null)}]
  | +- Stack Trace

An important thing is that the same method I´ve annotated with @Restrict is annotated with @Factory as you can see here:

    @Factory("cores")
  |     @Restrict
  |     public String selecionar() {
  |     	cores = dao.selecionarTodos(Cor.class);
  |     	return super.selecionar();
  | 	}

tks in advance

emerson fabiano

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4045559#4045559

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4045559




More information about the jboss-user mailing list