basichttpbinding

The request failed with HTTP status 415

寵の児 提交于 2019-12-11 06:41:46
问题 I am getting an exception when I try to call method from WCF...I am consuming WCF in windows application using framework 2.0 and my WCF uses the BasicHttpBinding option... The request failed with HTTP status 415: Cannot process the message because the content type 'text/xml; charset=utf-8' was not the expected type 'multipart/related; type="application/xop+xml"' 回答1: The client application is failing as it sends data on an Endpoint which is expecting MTOM messages. However, the client

Configuration.GetSection(“basicHttpBinding”) not reading that section from app.config file

那年仲夏 提交于 2019-12-11 04:41:49
问题 I have the following property: protected BasicHttpBinding Binding { get { var config = ConfigurationManager.GetSection("basicHttpBinding") as ServiceModelSectionGroup; foreach (ChannelEndpointElement bindings in config.Bindings.BasicHttpBinding.Bindings) { string binding = bindings.Binding; if (binding != null) { return new BasicHttpBinding(binding); } } return null; } } When I debug it, it fails with a null exception: Object reference not set to an instance of an object at this line: foreach

Delphi 7 Soap WCF Service using basicHttpBinding

蓝咒 提交于 2019-12-11 04:35:07
问题 I added a basicHttpBinding to an existing Service I have in production in order to expose it for use in Delphi. When I try to use the WSDLImporter from Delphi 7 on the wsdl file, it doesn't work right. A section in the resulting tlb says // ************************************************************************ // // The following types, referred to in the WSDL document are not being represented // in this file. They are either aliases[@] of other types represented or were referred // to but

WCF client with Client Certificate and Basic Authentication

随声附和 提交于 2019-12-11 04:33:31
问题 I need to access web services of one of our partners. Their services are secured with both a Client Certificate and Basic Authentication. I'm using WCF with BasicHttpBinding. I am able to hook up the cert using Transport level security. I know the cert is working because I'm no longer getting a 403 error, but I am getting a 401 because I can't pass the credentials along with the transport. From what I can see, I can only have one type of transport security scheme. How can I achieve this?

IIS 7 Restarts Automatically

泪湿孤枕 提交于 2019-12-11 02:08:46
问题 I have a WCF Service Deployed on IIS. (BasicHTTPBinding with [AspNetCompatibilityRequirements(RequirementsMode = AspNetCompatibilityRequirementsMode.Allowed)]) I have built custom in-memory session management and Now I am facing a strange problem that is IIS 7 Restarts Automatically without even throwing any kind of warning or error not even in EventLog. This problem leads to destroy the all available sessions. I discovered this issue after logging the Application_Start and Application_End

How to read basicHttpBinding defined in app.config file

瘦欲@ 提交于 2019-12-10 15:28:35
问题 I'm trying to figure out how to read how to read basicHttpBinding section defined in app.config file. I attempted to do it like I did the endpoint address but it does not work. Here is how I did my endpoint address: private EndpointAddress EndPointAddy { get { var config = ConfigurationManager.GetSection("system.serviceModel/Client") as ServiceModelSectionGroup; foreach (ChannelEndpointElement endpoint in config.Client.Endpoints) { Uri address = endpoint.Address; if (address != null) { return

BasicHttpBinding with TransportWithMessageCredential and clientCredentialType=“Windows”

那年仲夏 提交于 2019-12-09 20:02:28
问题 I am using this binding configuration on client and server: <basicHttpBinding> <binding name="BasicHttpBinding_IService1"> <security mode="TransportWithMessageCredential"> <transport clientCredentialType="Windows" /> </security> </binding> </basicHttpBinding> The client credentials seem to not be passed automagically (or are they?) this way like i assumed, so i need to know how to set them by myself. Will this even work? 回答1: You have to enable Windows Authentication on IIS . Look at the

WCF ServiceHost basicHttpBinding 503 error

守給你的承諾、 提交于 2019-12-09 03:36:52
问题 I'm trying to run a WCF ServiceHost as an NT Service on a Windows 2007 SP1 Server. The ServiceHost is reponsible for hosting a single service endpoint: a basicHttpBinding with the following address: http://localhost:5555/ToBlah When I run this ServiceHost on my local machine (Windows XP), it works fine - when I POST a SOAP message to it, I get back an HTTP 202 code ("Accepted"), which is the correct response for my service because the contract has IsOneWay=true. However, when I run this on my

Return JSON from WCF

拜拜、爱过 提交于 2019-12-08 08:36:40
问题 my WCF service is in .net framework 3.5,this WCF service will be used by PHP, so i have used basicHttpBinding (please suggest if any other better one). i am using below code/attribut on function to return JSON. [WebInvoke(Method = "POST", BodyStyle = WebMessageBodyStyle.Wrapped, ResponseFormat = WebMessageFormat.Json)] but its not returning JSON (its returning object). Please help me. NOTE: i found a solution but its for .NET Framework 4.0. but i need solution for 3.5. WCF 4.0 :

WCF client configuration for 3rd party SOAP 1.1 service with plain text username credentials over SSL

浪子不回头ぞ 提交于 2019-12-07 10:05:19
问题 I am trying to connect to a third party SOAP 1.1 service that requires SSL security and username/password credentials. An example of what is expected is: <soapenv:Header> <wsse:Security> <wsse:UsernameToken> <wsse:Username>username</wsse:Username> <wsse:Password>password</wsse:Password> </wsse:UsernameToken> </wsse:Security> </soapenv:Header> My client configuration is as follows: <system.serviceModel> <bindings> <basicHttpBinding> <binding name="thirdpartyservicebindingconfig"> <security