java - No assertion builder for type {http://schemas.xmlsoap.org/ws/2005/07/securitypolicy} -
i using ibm liberty 16.0.0.4
i trying call webservice through generated client classed using wsimport, when try call endpoint service got next warnings , error.
[warning ] no assertion builder type {http://schemas.xmlsoap.org/ws/2005/07/securitypolicy}transportbinding registered. [warning ] no assertion builder type {http://schemas.xmlsoap.org/ws/2005/07/securitypolicy}transporttoken registered. [warning ] no assertion builder type {http://schemas.xmlsoap.org/ws/2005/07/securitypolicy}httpstoken registered. [warning ] no assertion builder type {http://schemas.xmlsoap.org/ws/2005/07/securitypolicy}algorithmsuite registered. [warning ] no assertion builder type {http://schemas.xmlsoap.org/ws/2005/07/securitypolicy}basic256 registered. [warning ] no assertion builder type {http://schemas.xmlsoap.org/ws/2005/07/securitypolicy}layout registered. [warning ] no assertion builder type {http://schemas.xmlsoap.org/ws/2005/07/securitypolicy}lax registered. [warning ] no assertion builder type {http://schemas.xmlsoap.org/ws/2005/07/securitypolicy}includetimestamp registered. [warning ] no assertion builder type {http://schemas.xmlsoap.org/ws/2005/07/securitypolicy}signedsupportingtokens registered. [warning ] no assertion builder type {http://schemas.xmlsoap.org/ws/2005/07/securitypolicy}usernametoken registered. [error ] none of policy alternatives can satisfied. none of policy alternatives can satisfied.
do know if need add jars or real problem? or missing?
note: added security usernametoken have username , password in custom soaphandler
thanks :)
i found solution on enabling wssecurity on liberty server , needs enabled explicitly.
so used wssecurity-1.1 inside <featuremanager>
<feature>wssecurity-1.1</feature>
also sending credentials of username , password need use next code usernametoken
map ctx = ((bindingprovider) port).getrequestcontext(); ctx.put("ws-security.username", "username"); ctx.put("ws-security.password", "password");
and not adding usernametoken header using security soap element that
security.addchildelement("usernametoken", "wsse");
references
Comments
Post a Comment