Not sure; maybe try "headers['WWW-Authenticate']" first?

Dave

On Wed, Jan 12, 2011 at 4:50 PM, JOSE L MARTINEZ-AVIAL <jlm...@gmail.com>wrote:

> I launched an exception to get the stacktrace, and it calls OGNL:
>
> java.lang.Throwable
>        at
>
> com.spb.mvc.controller.web.struts2.json.ResponseJSONResult.setMyValue(ResponseJSONResult.java:29)
>        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>        at
>
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
>        at
>
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
>        at java.lang.reflect.Method.invoke(Method.java:597)
>        at ognl.OgnlRuntime.invokeMethod(OgnlRuntime.java:830)
>        at ognl.OgnlRuntime.callAppropriateMethod(OgnlRuntime.java:1253)
>        at ognl.OgnlRuntime.setMethodValue(OgnlRuntime.java:1454)
>        at
>
> ognl.ObjectPropertyAccessor.setPossibleProperty(ObjectPropertyAccessor.java:85)
>        at
> ognl.ObjectPropertyAccessor.setProperty(ObjectPropertyAccessor.java:162)
>        at
>
> com.opensymphony.xwork2.ognl.accessor.ObjectAccessor.setProperty(ObjectAccessor.java:28)
>        at ognl.OgnlRuntime.setProperty(OgnlRuntime.java:2225)
>        at ognl.ASTProperty.setValueBody(ASTProperty.java:127)
>        at ognl.SimpleNode.evaluateSetValueBody(SimpleNode.java:220)
>        at ognl.SimpleNode.setValue(SimpleNode.java:301)
>        at ognl.Ognl.setValue(Ognl.java:737)
>        at com.opensymphony.xwork2.ognl.OgnlUtil.setValue(OgnlUtil.java:198)
>        at
>
> com.opensymphony.xwork2.ognl.OgnlUtil.internalSetProperty(OgnlUtil.java:394)
>        at
> com.opensymphony.xwork2.ognl.OgnlUtil.setProperty(OgnlUtil.java:149)
>        at
>
> com.opensymphony.xwork2.ognl.OgnlReflectionProvider.setProperty(OgnlReflectionProvider.java:91)
>        at
> com.opensymphony.xwork2.ObjectFactory.buildResult(ObjectFactory.java:221)
>        at
>
> com.opensymphony.xwork2.DefaultActionInvocation.createResult(DefaultActionInvocation.java:209)
>        at
>
> com.opensymphony.xwork2.DefaultActionInvocation.executeResult(DefaultActionInvocation.java:356)
>        at
>
> com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:266)
>        at
>
> com.spb.mvc.security.authoritation.web.AuthoritationInterceptor.intercept(AuthoritationInterceptor.java:100)
>        at
>
> com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:237)
>        at
>
> com.spb.mvc.controller.web.BusinessContextInterceptor.intercept(BusinessContextInterceptor.java:30)
>        at
>
> com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:237)
>        at
>
> com.spb.mvc.security.authentication.web.AuthenticationInterceptor.intercept(AuthenticationInterceptor.java:53)
>        at
>
> com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:237)
>
>  Any idea on how to avoid this behaviour?
>
> 2011/1/12 Dave Newton <davelnew...@gmail.com>
>
> > I wonder if that's an OGNL thing.
> >
> > Dave
> >
> > On Wed, Jan 12, 2011 at 12:24 PM, JOSE L MARTINEZ-AVIAL <
> jlm...@gmail.com
> > >wrote:
> >
> > > Hi all,
> > >
> > >    I'm using Struts .2.1.8.1, and I've found a problem when I use
>  result
> > > type httpheader and I try to use a header name with a hyphen. They
> don't
> > > get
> > > sent. For example, the following result definition:
> > >
> > > <result name="mvc.security.authentication.ntlm.solicited"
> > > type="httpheader">
> > >
> > >    <param name="status">401</param>
> > >
> > >    <param name="headers.WWW-Authenticate">NTLM</param>
> > >
> > >    <param name="headers.a">my header</param>
> > >
> > >    <param name="headers.WWWAuthenticate">NTLM</param>
> > >
> > > </result>
> > >
> > >    I receive the headers "a" and "WWWAuthenticate", but no the header
> > > "WWW-Authenticate". Is there any way to fix this behaviour?
> > >
> > >
> > >
> > >    Thanks.
> > >
> > >
> > >
> > > Jose
> > >
> >
>

Reply via email to