CoreWCF / CoreWCF/CoreWCF

[Bug]: Soap11WSAddressingAugust2004 failing

Open
#1,294 4 comments 0 reactions 0 assignees View on GitHub
bug
Dominant language
C#
Stars
1.8k
Forks
320
PR merge metrics
No merged PRs in 30d

Description

### Duplicate ?

- [X] I have searched issues/discussions and did not find other issues/discussions reporting this bug.

### Product version

1.5.1

### Describe expected behavior

SOAP message should reach endpoint

### Describe actual behavior

Internal error in CoreWCF while processing SOAP request

### Which binding

CustomBinding

### security

None

### Which .NET version

.NET 6

### Which os platform

Windows

### Code snippet used to reproduce the issue

```c#
CustomBinding customBindingSoap11 = new CustomBinding(new BasicHttpBinding());
var encoding = customBindingSoap11.Elements.Find();
encoding.MessageVersion = MessageVersion.Soap11WSAddressingAugust2004;
...
// Add the Service
builder.AddService(serviceOptions =>
{
})
// Add a BasicHttpBinding endpoint
.AddServiceEndpoint(customBindingSoap11, "/someendpoint.asmx", endpoint =>
{
})
```

### Stacktrace if any

```shell
fail: Microsoft.AspNetCore.Server.Kestrel[13]
Connection id "0HMVB55JE925V", Request id "0HMVB55JE925V:00000002": An unhandled exception was thrown by the application.
System.ObjectDisposedException: Message is closed.
at CoreWCF.Channels.BufferedMessage.get_Properties()
at CoreWCF.Channels.AspNetCoreReplyChannel.HandleRequest(HttpContext context)
at CoreWCF.Channels.RequestDelegateHandler.HandleRequest(HttpContext context)
at CoreWCF.Channels.ServiceModelHttpMiddleware.InvokeAsync(HttpContext context)
at CoreWCF.Channels.MetadataMiddleware.InvokeAsync(HttpContext context)
at Microsoft.AspNetCore.Watch.BrowserRefresh.BrowserRefreshMiddleware.InvokeAsync(HttpContext context)
at Microsoft.AspNetCore.Server.Kestrel.Core.Internal.Http.HttpProtocol.ProcessRequests[TContext](IHttpApplication`1 application)
```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.