I am facing this error when I am trying to upload excel file (length around 4 MB) on swagger api (.Net core 3.1). Its working on local as well as on other Azure app services (azure.net) but when I am trying to configure my code on azure virtual machine IIS, this error is coming on the domain api.
I tried lot of things adding headers, allowing CORS, increasing maxuploadlength, enabling SSL but nothing seems work. Mainly its occurring on application configured on a azure VM IIS server with SSL domain.
Please check if any below points are the cause.
References: