(332) 331-8677

BadHttpRequestException: Request body too large

Solution to this error is to add parameter [RequestSizeLimit(100_000_000)] before the action of the controller
[HttpPost]
[ValidateAntiForgeryToken]
[RequestSizeLimit(100_000_000)]
public async Task<IActionResult> Create([Bind("Id,Name,File,CatalogId")] Certificate certificate)
{
    if (ModelState.IsValid)
    {
        _context.Add(certificate);
        await _context.SaveChangesAsync();
        return RedirectToAction(nameof(Index));
    }
    return View(certificate);
}