Announcement Announcement Module
Collapse
No announcement yet.
POM for spring-ws-security based application Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • POM for spring-ws-security based application

    Hi

    I'm struggling to construct a POM that does not exhibit classpath errors using the following mix of components - Does anybody have a POM they would be willing to share:

    jre 1.5
    spring-ws-security 2.1 (using xwss:SecurityConfiguration)
    spring-xx 3.1

    I'm using WebServiceTemplate for testing, Currently using jetty but don't wish to let this bring a level of confusion / miss-direction.


    Starting just with spring jars, running my junit tests I get

    com.sun.xml.bind.v2.ContextFactory not found
    so i add: jaxb-impl 2.2

    javax.xml.soap.SOAPException not found
    so I add: saaj-impl 1.3 (provided)

    com.sun.org.apache.xerces.internal.dom.DocumentImp l not found
    so I add: jaxp-ri-1.4.jar

    com.sun.org.apache.xml.internal.security.Init not found
    required by xws-security (1.3.1) required by spring-ws-security (2.1.2.RELEASE)
    not sure how to fix as anthing i do just brings more classpath issues.

    Alternatively does anybody have a strategy that can be used to address the classpath issues?

  • #2
    finally resolved it,

    Code:
      <dependencies>
          <!-- This implemention uses woodstock stax xml pull parser, replaces ZephyrParserFactory -->
            <dependency>
                <groupId>com.sun.xml.wsit</groupId>
                <artifactId>wsit-rt</artifactId>
                <version>1.3.1</version>
                <type>jar</type>
            </dependency>
            <dependency>
                <groupId>org.codehaus.woodstox</groupId>
                <artifactId>wstx-asl</artifactId>
                <version>3.2.0</version>
                <exclusions>
                    <exclusion>
                        <groupId>stax</groupId>
                        <artifactId>stax-api</artifactId>
                    </exclusion>
                </exclusions>
            </dependency>
    
            <dependency>
                <groupId>org.springframework.ws</groupId>
                <artifactId>spring-ws-core</artifactId>
                <version>${spring.ws.version}</version>
            </dependency>
            <dependency>
                <groupId>org.springframework</groupId>
                <artifactId>spring-webmvc</artifactId>
                <version>${spring.version}</version>
            </dependency>
            <dependency>
                <groupId>org.springframework</groupId>
                <artifactId>spring-web</artifactId>
                <version>${spring.version}</version>
            </dependency>
            <dependency>
                <groupId>org.springframework</groupId>
                <artifactId>spring-context</artifactId>
                <version>${spring.version}</version>
            </dependency>
            <dependency>
                <groupId>org.springframework</groupId>
                <artifactId>spring-core</artifactId>
                <version>${spring.version}</version>
            </dependency>
            <dependency>
                <groupId>org.springframework</groupId>
                <artifactId>spring-beans</artifactId>
                <version>${spring.version}</version>
            </dependency>
            <dependency>
                <groupId>org.springframework</groupId>
                <artifactId>spring-oxm</artifactId>
                <version>${spring.version}</version>
            </dependency>
    
            <dependency>
                <groupId>org.springframework.ws</groupId>
                <artifactId>spring-ws-security</artifactId>
                <version>${spring.ws.version}</version>
            </dependency>
            <dependency>
                <groupId>org.springframework.security</groupId>
                <artifactId>spring-security-core</artifactId>
                <version>${spring.version}</version>
            </dependency>
            <dependency>
                <groupId>org.apache.ws.security</groupId>
                <artifactId>wss4j</artifactId>
                <version>1.6.10</version>
            </dependency>
    
            <dependency>
                <groupId>org.apache.ws.commons.schema</groupId>
                <artifactId>XmlSchema</artifactId>
                <version>1.4.2</version>
            </dependency>
    
            <dependency>
                <groupId>org.slf4j</groupId>
                <artifactId>slf4j-api</artifactId>
                <version>1.6.1</version>
            </dependency>
            <dependency>
                <groupId>org.slf4j</groupId>
                <artifactId>slf4j-log4j12</artifactId>
                <version>1.6.1</version>
            </dependency>
            <dependency>
                <groupId>log4j</groupId>
                <artifactId>log4j</artifactId>
                <version>1.2.15</version>
            </dependency>
    
          <!-- resolves: javax.xml.soap.SOAPException -->
            <dependency>
                <groupId>com.sun.xml.messaging.saaj</groupId>
                <artifactId>saaj-impl</artifactId>
                <version>1.3.21</version>
                <exclusions>
                    <exclusion>
                         <!-- 1.3.5 requires JDK 1.6 -->
                        <artifactId>javax.xml.soap-api</artifactId>
                        <groupId>javax.xml.soap</groupId>
                    </exclusion>
                    <exclusion>
                        <!-- 1.9.3 requires JDK 1.6 -->
                        <artifactId>mimepull</artifactId>
                        <groupId>org.jvnet.mimepull</groupId>
                    </exclusion>
                </exclusions>
            </dependency>        
            <dependency>
                <groupId>javax.xml.soap</groupId>
                <artifactId>saaj-api</artifactId>
                <version>1.3.4</version>
            </dependency>
            <dependency>
                <groupId>org.jvnet.mimepull</groupId>
                <artifactId>mimepull</artifactId>
                <version>1.8</version>
            </dependency>        
    
            <!-- resolves: com.sun.org.apache.xerces.internal.dom.DocumentImp -->
            <dependency>
                <groupId>com.sun.xml.parsers</groupId>
                <artifactId>jaxp-ri</artifactId>
                <version>1.4.5</version>
            </dependency>
    
            <!-- resolves: com.sun.org.apache.xml.internal.security.Init -->
            <dependency>
                <groupId>com.sun.org.apache.xml.security</groupId>
                <artifactId>xmlsec</artifactId>
                <version>2.0</version>
            </dependency>
    
            <!-- resolves: com.sun.xml.bind.v2.ContextFactory -->
            <dependency>
                <groupId>com.sun.xml.bind</groupId>
                <artifactId>jaxb-impl</artifactId>
                <version>2.2</version>
            </dependency>
    
        </dependencies>
    
        <properties>
            <spring.version>3.1.3.RELEASE</spring.version>
            <spring.ws.version>2.1.2.RELEASE</spring.ws.version>
        </properties>

    Comment


    • #3
      Hi all,

      This is a "me too" post. Our project is getting dependency failures for: spring-ws-security on: com.sun.xml.wsit.

      The Maven links for these modules from MVN Repository spring-ws-security come up empty.

      There were some comments about either wsit-rt and xws-security as 'legacy'.

      The point in question is if you don't have these modules were can they be 'got'? Secondly, are they widthdrawn from use for some reason? I am not getting hits for Spring-ws-security :: 2.1.3 back to 2.0.1.

      Is there a resolution?

      Thanks in advance.

      ... Will

      Comment


      • #4
        try
        http://mavenhub.com/mvn/thirdparty-r.../wsit-rt/1.3.1

        Comment

        Working...
        X