title: Spring WS-Security visible in WSDL
body: <p>I've implemented authentication through WS-Security on my webservice as described at <a href="http://static.springframework.org/spring-ws/sites/1.5/reference/html/security.html" rel="nofollow noreferrer">http://static.springframework.org/spring-ws/sites/1.5/reference/html/security.html</a>, like so:</p>
  
  <pre><code>&lt;bean id="callbackHandler" class="org.springframework.ws.soap.security.wss4j.callback.SimplePasswordValidationCallbackHandler"&gt;
      &lt;property name="users"&gt;
          &lt;props&gt;
              &lt;prop key="bart"&gt;arnie&lt;/prop&gt;
          &lt;/props&gt;
      &lt;/property&gt;
  &lt;/bean&gt;
  
  &lt;bean id="annotationMapping" class="org.springframework.ws.server.endpoint.mapping.PayloadRootAnnotationMethodEndpointMapping"&gt;
      &lt;property name="interceptors"&gt;
          &lt;list&gt;
              &lt;bean class="org.springframework.ws.soap.security.wss4j.Wss4jSecurityInterceptor"&gt;
                  &lt;property name="validationActions" value="UsernameToken" /&gt;
                  &lt;property name="securementActions" value="NoSecurity" /&gt;
                  &lt;property name="validationCallbackHandler" ref="callbackHandler" /&gt;
              &lt;/bean&gt; ...
  </code></pre>
  
  <p>However, clients (like SoapUI) don't know that they should use security, because it's not mentioned in the WSDL. How can I get it to be? This is how I generate it:</p>
  
  <pre><code>&lt;bean id="qwertyService" class="org.springframework.ws.wsdl.wsdl11.DefaultWsdl11Definition"&gt;
      &lt;property name="schemaCollection" ref="schemaCollection" /&gt;
      &lt;property name="portTypeName" value="QwertyService" /&gt;
      &lt;property name="locationUri" value="/QwertyService/" /&gt;
      &lt;property name="targetNamespace" value="http://www.ead2.nl/demo/wsdl" /&gt;
  &lt;/bean&gt;
  </code></pre>