axis-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ruchith Fernando" <ruchith.ferna...@gmail.com>
Subject Re: [Axis2/Rampart/WS-SecurityPolicy] NullPointerException on request
Date Thu, 08 Feb 2007 02:26:59 GMT
Hi,

On 2/8/07, Paul.Holmes@dds.net <Paul.Holmes@dds.net> wrote:
>
> OK, that fixed it, thanks!  I just assumed that because these jars were in rampart.mar
file that they didn't need to be in the classpath separately as well.
>
> Which of course raises the question -- why put these jars in the .mar if they must be
available separately anyway?

Users will have to use some classes in wss4j (which rampart depends
on) in certain ways of configuring rampart - Example : password
callback handler. And we run into a lot of classloading issues where
the user's classes are loaded from one classloader and rampart loads
them form another. Therefore we have to have all these jars in the
global classpath of axis2.

In the new rampart we have moved all these jars out of rampart module.

> BTW, I think I uncovered a minor bug along the way: if Rampart is a globally engaged
module and you try calling a web service that doesn't exist, you get a NullPointerException
in RampartMessageData.getServicePolicyKey() when it calls msgCtx.getAxisService().getName(),
because msgCtx.axisService is null.  (Normally you get a "service not found" error from InstanceDispatcher.)
>

Please create a JIRA issue at :
https://issues.apache.org/jira/browse/RAMPART

Thanks,
Ruchith

>
>
>
>
>  "Ruchith Fernando" <ruchith.fernando@gmail.com>
>
> 02/07/2007 09:30 AM
>
> Please respond to
>  axis-user@ws.apache.org
>
>
> To axis-user@ws.apache.org
>
> cc
>
>
> Subject Re: [Axis2/Rampart/WS-SecurityPolicy] NullPointerException on request
>
>
>
>
>
>
>
>
> Hi,
>
>  Do you have the following in your classpath:
>
>  axis2-rahas-1.1.jar
>  axis2-secpolicy-1.1.jar
>  axis2-security-1.1.jar
>
>  Basically you will need to have all jars that are provided with the
>  lib dir of rampart-1.1 release in your classpath.
>
>  Thanks,
>  Ruchith
>
>  On 2/7/07, Paul.Holmes@dds.net <Paul.Holmes@dds.net> wrote:
>  >
>  > Hi, I'm having a problem using Axis2-1.1.1 and Rampart-1.1 with the new
>  >  WS-SecurityPolicy configurations.  Specifically, I get a
>  > NullPointerException
>  >  on the server side that gets propogated back to the client via an
>  >  AxisFault every time I send a request secured with WS-Security.  Here's the
>  > server console when it happens:
>  >
>  >  Unknown top level PED found:
>  >  org.apache.neethi.builders.xml.XmlPrimtiveAssertion
>  >  Unknown top level PED found:
>  >  org.apache.neethi.builders.xml.XmlPrimtiveAssertion
>  >  Unknown top level PED found:
>  >  org.apache.neethi.builders.xml.XmlPrimtiveAssertion
>  >  Unknown top level PED found:
>  >  org.apache.neethi.builders.xml.XmlPrimtiveAssertion
>  >  2007-02-06 14:26:45,171 : AxisServlet.doPost :
>  >  java.lang.NullPointerException
>  >
>  >  It doesn't seem to matter what web service I call -- I've even tried
>  >  plugging in the sample .aar's that come with the Rampart 1.1 distribution,
>  >  and they give the error as well.  But it only happens when I use Rampart
>  >  with the WS-SecurityPolicy configuration.
>  >
>  >  Through much pain and perseverence, I *think* I've tracked down the source
>  >  of the error to missing "AssertionBuilder" objects.  When Axis2 starts up,
>  >  it looks for instances of AssertionBuilder objects to register for later
>  >  use.  Rampart has a whole mess of these things, apparently one for each
>  > possible XML tag in the WS-SecurityPolicy spec and its RampartConfig
>  >  extensions.  But for some reason the AssertionBuilders are not being
>  >  registered when Axis starts up, so when it parses the security config it
>  >  jams everything into the default XmlPrimitiveAssertion objects instead.
>  >  Then when it tries to process a request and looks for the Policy to apply
>  > to it, the RampartConfig assertions it expects are missing, and it spits
>  > out an NPE.
>  >
>  > Can anyone tell me what's going on?  Is this a bug in Axis2/Rampart, or is
>  >  there something wrong with my config?  Thanks!
>  >
>
>
>  --
>  www.ruchith.org
>  www.wso2.org
>
>  ---------------------------------------------------------------------
>  To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
>  For additional commands, e-mail: axis-user-help@ws.apache.org
>
>
>



-- 
www.ruchith.org
www.wso2.org

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


Mime
View raw message