Поделиться через


Connect to WCF LOB Adapter hosted as WCF service using ClientCredentials

On the website https://msdn.microsoft.com/en-us/library/dd451003.aspx, we have a step by step guide to publish the Siebel adapter as a WCF Service in IIS and then have MOSS consume the data using that service. In this approach, credentials are pass by MOSS to the adapter using custom HTTP headers.

 

If instead you want to consume this service from a .net application or any client that wants to pass the credentials using the ClientCredentials object, this is how you will go about doing it. Follow the steps on https://msdn.microsoft.com/en-us/library/dd450994.aspx that gives detailed instructions about publishing the WCF service. There are 2 differences though

 

1. In the “Configure service and endpoint behaviors” page, for “AuthenticationType” you will need to select “ClientCredentialUsernamePassword” (as opposed to “HTTPUsernamePassword” that the tutorial specifies)

 

 

 

2. In the “Configure the service endpoint binding and address” page, click on the BindingConfiguration (the … following BasicHttpBindingElement) to customize the binding. Set Security Mode to “TransportWithMessageCredential”

 

 

 

Follow the rest of the instructions for publishing the service. You can now connect to the service using a .net proxy application and pass the credentials using the ClientCredentials object.

Comments

  • Anonymous
    February 25, 2010
    Hi ,I am following your article , what i am trying to do is use SQL adapter to create a wcf service and host it on IIS , I am not able to find a way to pass the credentials to my sql server to do select , the SQL always get a empty user from my application , How do i access the service from my ASP.NET application , i am just creating a class from the WSDL and including in my project , but there is no way to pass the clientCreditialthanks-raghav