You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cxf.apache.org by lv <lv...@live.cn> on 2013/02/17 04:13:40 UTC

Cannot find web service policy in wsdl

users@cxf.apache.org

I use cxf to create web services from java code. Then I add weblogic web service security policy.
However, after deploying to weblogic 12c, I cannot see the security part in WSDL.
Can I use weblogic web service security to cxf web services?
Or I must write security policy by myself and add them to  cxf web services?

import weblogic.jws.Policies;
import weblogic.jws.Policy;
 
@Component
@WebService(name="appServiceSecurity",
        serviceName="appServiceSrcSecurity",
        targetNamespace="http://com.ws.su"            
)
@Policies({
            @Policy(uri="policy:Auth.xml", direction=Policy.Direction.inbound),
            @Policy(uri="policy:Sign.xml"),
            @Policy(uri="policy:Encrypt.xml")
})
@SOAPBinding(style = SOAPBinding.Style.DOCUMENT,
        use=SOAPBinding.Use.LITERAL,
        parameterStyle=SOAPBinding.ParameterStyle.WRAPPED
)
 
 
public class AppServiceSecurity{
...........................
}

 		 	   		  

Re: Cannot find web service policy in wsdl

Posted by Glen Mazza <gl...@gmail.com>.
Weblogic security is not understood by CXF; you'll need to add
CXF-compatible policies instead.

Glen

On 02/16/2013 10:13 PM, lv wrote:
> users@cxf.apache.org
>
> I use cxf to create web services from java code. Then I add weblogic web service security policy.
> However, after deploying to weblogic 12c, I cannot see the security part in WSDL.
> Can I use weblogic web service security to cxf web services?
> Or I must write security policy by myself and add them to  cxf web services?
>
> import weblogic.jws.Policies;
> import weblogic.jws.Policy;
>  
> @Component
> @WebService(name="appServiceSecurity",
>         serviceName="appServiceSrcSecurity",
>         targetNamespace="http://com.ws.su"            
> )
> @Policies({
>             @Policy(uri="policy:Auth.xml", direction=Policy.Direction.inbound),
>             @Policy(uri="policy:Sign.xml"),
>             @Policy(uri="policy:Encrypt.xml")
> })
> @SOAPBinding(style = SOAPBinding.Style.DOCUMENT,
>         use=SOAPBinding.Use.LITERAL,
>         parameterStyle=SOAPBinding.ParameterStyle.WRAPPED
> )
>  
>  
> public class AppServiceSecurity{
> ...........................
> }
>
>