-
Notifications
You must be signed in to change notification settings - Fork 5.3k
Description
Hi, we have an issue whereby an 'Expect: 100-Continue' header is being automatically added to all HttpClient POST/PUT requests when our .NET Core web api service is deployed to a linux environment (specifically Ubuntu 14.04/16.04). The header is not added when the service is run in a windows environment, both from within Visual Studio and directly in the console using dotnet run.
Logging of the headers of the HttpClient in the service prior to calling SendAsync shows that the Expect header is not set, however logging of the HTTP requests on the server using tcpdump show that it is being set.
I have tried to remove the headers via, client.DefaultRequestHeaders.ExpectContinue = false; and client.DefaultRequestHeaders.Expect.Clear(); however they are still added.
Our issue is that our service must pass through a squid proxy whose version does not support the Expect header. We do not have control over this proxy and it's unlikely we will be able to update the version in the near future.
Cheers,
Luke