WCF WSS4J Interop
April 5, 2009
Recently I had to work on an interop scenario where WCF client needed to call a WSS4J service. After a bit of experimentation, I came up with the following configuration.
Here are some of the key settings to note:
Authentication Mode MutualCertificate
Message Protection Order SignBeforeEncrypt
SOAP Version 1.1
Algorithm Basic128Rsa15
Message Security Version WSSecurity10WSTrustFebruary2005WSSecureConversationFebruary2005WSSecurityPolicy11BasicSecurityProfile10
<?xml version=“1.0“ encoding=“utf-8“ ?>
<configuration>
<system.serviceModel>
<client>
<endpoint address=“http://gp64156.exampleCorp.net:8080/eservices/aService“
behaviorConfiguration=“ClientCertBehavior“ binding=“customBinding“
bindingConfiguration=“JavaInterop“ contract=“exampleCorp.Proxy.aProfileManager“
name=“UserProfileManager“>
<identity>
<dns value=“userprofilews“ />
</identity>
</endpoint>
</client>
<bindings>
<customBinding>
<binding name=“JavaInterop“>
<security defaultAlgorithmSuite=“Basic128Rsa15“ allowSerializedSigningTokenOnReply=“true“
authenticationMode=“MutualCertificate“ requireDerivedKeys=“false“
securityHeaderLayout=“Lax“ includeTimestamp=“false“ messageProtectionOrder=“SignBeforeEncrypt“
messageSecurityVersion=“WSSecurity10WSTrustFebruary2005WSSecureConversationFebruary2005WSSecurityPolicy11BasicSecurityProfile10“>
<localClientSettings detectReplays=“false“ />
</security>
<textMessageEncoding messageVersion=“Soap11“ />
<httpTransport />
</binding>
</customBinding>
</bindings>
<behaviors>
<endpointBehaviors>
<behavior name=“ClientCertBehavior“>
<clientCredentials>
<clientCertificate findValue=“CN=client.com“ />
<serviceCertificate>
<defaultCertificate findValue=“userprofilews“ storeLocation=“LocalMachine“
storeName=“TrustedPeople“ x509FindType=“FindByIssuerName“ />
</serviceCertificate>
</clientCredentials>
</behavior>
</endpointBehaviors>
</behaviors>
</system.serviceModel>
</configuration>
July 13, 2009 at 3:17 am
Please show me how to configure Wss4j services.
Please help me! I spent a lot of time to solve this problem.