Skip to content

Commit 0a09b70

Browse files
committed
Disable maximum request body size
1 parent 2673ba7 commit 0a09b70

File tree

1 file changed

+4
-0
lines changed
  • sample/FubarDev.WebDavServer.Sample.AspNetCore

1 file changed

+4
-0
lines changed

sample/FubarDev.WebDavServer.Sample.AspNetCore/Program.cs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,11 +49,15 @@ private static IWebHostBuilder ConfigureHosting(IWebHostBuilder builder, IConfig
4949
{
5050
opt.Authentication.Schemes = AuthenticationSchemes.NTLM;
5151
opt.Authentication.AllowAnonymous = true;
52+
opt.MaxRequestBodySize = null;
5253
});
5354
}
5455
else
5556
{
5657
IsKestrel = true;
58+
builder = builder
59+
.UseKestrel(
60+
opt => { opt.Limits.MaxRequestBodySize = null; });
5761
}
5862

5963
return builder;

0 commit comments

Comments
 (0)