Questions tagged [kestrel-http-server]

Kestrel is a HTTP server that is built-in to ASP.NET Core.

Kestrel is an open-source web server based on libuv and developed by Microsoft. The project home is on GitHub.

822 questions
6
votes
1 answer

Does it require https in Kestrel behind my https apache proxy server?

I am not quite clear about the idea whether the Kestrel server needs to be encrypted as a localhost server. I use Apache with HTTPS as the proxy server for Kestrel server. Does it require to run https in Kestrel as well? In theory, what passes…
6
votes
0 answers

Hosting Asp.NET Core on IIS + Kestrel: randomly slow response

I'm facing a problem with IIS + Kestrel hosting of asp.net core application (web api). Sometimes response delay is about 5sec. In such case Chrome shows "GET net::ERR_CONNECTION_TIMED_OUT" (but Firefox waits until response) It only happens on IIS,…
user1820686
  • 2,008
  • 5
  • 25
  • 44
6
votes
1 answer

How to get HttpContext from within function performing ClientCertificateValidation on Kestrel asp.net core?

I have an asp.net core self hosted application within Kestrel. Part of the .UseKestrel options within my Program.cs Main() function is to use the ClientCertificateValidation() functionality to have my own function validate client certificates. This…
Paul W.
  • 299
  • 1
  • 5
  • 15
6
votes
2 answers

Rewriting forward slashes in a query parameter

In my asp.net core app (angular 4 front end) I accept a URL like this: example.com/report;url=http%3A%2F%2Fexample2.com I would like to create a rewrite rule that allowed people to enter the following…
Guerrilla
  • 13,375
  • 31
  • 109
  • 210
6
votes
2 answers

How do I get visibility / debug high memory usage in a dotnet Core application running on IIS

We have an application we have recent ported to use the Aspnet boilerplate framework and are having a number of issues regarding memory usage. Our initial symptom was intense memory usage with no alleviation in times of high use. Memory use…
6
votes
1 answer

Is Kestrel sufficient for an asp.net core website running on AWS ECS behind an ALB?

I'm getting ready to deploy an ASP.NET Core MVC website to production. The application will be deployed to AWS ECS (EC2 Container Service). Kestrel isn't recommended for serving traffic from the internet, and it is recommended that a reverse proxy…
6
votes
1 answer

Modify static file response in ASP.NET Core

I serve a bunch of static files in my app with app.UseStaticFiles(). I'd like to inject some additional markup into the response for a particular HTML file before it's sent. My first attempt was to add middleware like this before the static files…
Martin Wedvich
  • 2,158
  • 2
  • 21
  • 37
6
votes
1 answer

Cannot change Kestrel listening port from command line

I have the following entry point: public static void Main(string[] args) { var config = new ConfigurationBuilder() .SetBasePath(Directory.GetCurrentDirectory()) .AddJsonFile("hosting.json", optional: true) …
Set
  • 47,577
  • 22
  • 132
  • 150
6
votes
1 answer

Hosting ASP.NET 5 WebAPI in IIS using a virtual directory/application

I am trying to host a new ASP.NET 5 WebAPI project in IIS, and I am using the ASP.NET 5 RC 1 runtime. The project that I am using is the standard generated template for a new ASP.NET 5 WebAPI project. (No code changes.) I have successfully…
6
votes
1 answer

Unable to load application or execute command 'Microsoft.AspNet.Server.Kestrel'

I am trying to deploy my ASP.NET 5 WebApi to a remote server (Windows server 2008 R2) and am having trouble getting it to run correctly with IIS. project.json { "webroot": "wwwroot", "version": "1.0.0-*", "dependencies": { "App.Data":…
Amine
  • 1,198
  • 11
  • 19
5
votes
0 answers

Intermitted .NET 6 web application crash using Kestrel

I have a .NET 6 web application that crashes intermittently when using Kestrel: System.Net.Sockets.SocketException (995): The I/O operation has been aborted because of either a thread exit or an application request. at…
Keith
  • 150,284
  • 78
  • 298
  • 434
5
votes
2 answers

Hosting blazor wasm asp.net core hosted app in kestrel

I am having troubles hosting the blazor wasm asp.net core hosted application.. The solution has 3 projects: Client, Shared, and Server. when I run the command dotnet publish --configuration Release it publishes the libraries to their respective…
Alex
  • 4,607
  • 9
  • 61
  • 99
5
votes
1 answer

ASP.NET core 3.1: does ConfigureAppConfiguration interacts with launchSettings.json?

I'm experiencing a strange behavior when launching an ASP.NET core 3.1 web application from Visual Studio 2019 using kestrel (I mean the launching profile which does not use IIS express). I have created a minimal application to reproduce the…
5
votes
2 answers

HTTPS outbound requests time increases to 5 min after 14-21 days on an instance running a product based on IdentityServer 4

Running an ASP.Net Core application based on IdentityServer 4 on an AWS cluster, after 14-21 days all outgoing HTTPS requests take 5min or more to finish. After an investigation found that the WinHTTP Web Proxy Auto-Discovery Service dies with the…
5
votes
1 answer

How to Change ASP.NET Core's Built-In Web-Server (Kestrel) Default IP Binding, from 127.0.0.1 to 0.0.0.0?

I Installed .NET Core SDK v3.1 on an Ubuntu VPS, and I am now experimenting with ASP.NET Core projects. I use dotnet new webapp -o --no-https to create an ASP.NET Core project, and dotnet run to run it, using .NET Core's built-in Web…
spaceman
  • 1,061
  • 1
  • 11
  • 31