diff --git a/Marco.Pms.Services/Program.cs b/Marco.Pms.Services/Program.cs index bd87f5e..6719848 100644 --- a/Marco.Pms.Services/Program.cs +++ b/Marco.Pms.Services/Program.cs @@ -147,9 +147,16 @@ if(jwtSettings != null && jwtSettings.Key != null) } builder.Services.AddSingleton(jwtSettings); +builder.WebHost.ConfigureKestrel(options => +{ + options.AddServerHeader = false; // Disable the "Server" header +}); var app = builder.Build(); +app.UseMiddleware(); +app.UseMiddleware(); +app.UseMiddleware(); @@ -177,9 +184,7 @@ app.UseStaticFiles(); // Enables serving static files app.UseHttpsRedirection(); -app.UseMiddleware(); -app.UseMiddleware(); -app.UseMiddleware(); + app.UseAuthorization();