Add comments regarding HSTS max age
This commit is contained in:
parent
d9e71527e8
commit
11c6ebea2e
|
|
@ -147,6 +147,7 @@ namespace Company.WebApplication1
|
||||||
{
|
{
|
||||||
app.UseExceptionHandler("/Error");
|
app.UseExceptionHandler("/Error");
|
||||||
#if (RequiresHttps)
|
#if (RequiresHttps)
|
||||||
|
// The default HSTS value is 30 days. You may want to change this for production scenarios, see https://aka.ms/aspnetcore-hsts.
|
||||||
app.UseHsts();
|
app.UseHsts();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -146,6 +146,7 @@ namespace Company.WebApplication1
|
||||||
{
|
{
|
||||||
app.UseExceptionHandler("/Home/Error");
|
app.UseExceptionHandler("/Home/Error");
|
||||||
#if (RequiresHttps)
|
#if (RequiresHttps)
|
||||||
|
// The default HSTS value is 30 days. You may want to change this for production scenarios, see https://aka.ms/aspnetcore-hsts.
|
||||||
app.UseHsts();
|
app.UseHsts();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -31,6 +31,7 @@ type Startup private () =
|
||||||
else
|
else
|
||||||
app.UseExceptionHandler("/Home/Error") |> ignore
|
app.UseExceptionHandler("/Home/Error") |> ignore
|
||||||
#if (!NoHttps)
|
#if (!NoHttps)
|
||||||
|
// The default HSTS value is 30 days. You may want to change this for production scenarios, see https://aka.ms/aspnetcore-hsts.
|
||||||
app.UseHsts() |> ignore
|
app.UseHsts() |> ignore
|
||||||
|
|
||||||
app.UseHttpsRedirection() |> ignore
|
app.UseHttpsRedirection() |> ignore
|
||||||
|
|
|
||||||
|
|
@ -56,6 +56,7 @@ namespace Company.WebApplication1
|
||||||
#if (RequiresHttps)
|
#if (RequiresHttps)
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
// The default HSTS value is 30 days. You may want to change this for production scenarios, see https://aka.ms/aspnetcore-hsts.
|
||||||
app.UseHsts();
|
app.UseHsts();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -29,6 +29,7 @@ type Startup private () =
|
||||||
app.UseDeveloperExceptionPage() |> ignore
|
app.UseDeveloperExceptionPage() |> ignore
|
||||||
#if (!NoHttps)
|
#if (!NoHttps)
|
||||||
else
|
else
|
||||||
|
// The default HSTS value is 30 days. You may want to change this for production scenarios, see https://aka.ms/aspnetcore-hsts.
|
||||||
app.UseHsts() |> ignore
|
app.UseHsts() |> ignore
|
||||||
|
|
||||||
app.UseHttpsRedirection() |> ignore
|
app.UseHttpsRedirection() |> ignore
|
||||||
|
|
@ -37,4 +38,4 @@ type Startup private () =
|
||||||
#endif
|
#endif
|
||||||
app.UseMvc() |> ignore
|
app.UseMvc() |> ignore
|
||||||
|
|
||||||
member val Configuration : IConfiguration = null with get, set
|
member val Configuration : IConfiguration = null with get, set
|
||||||
|
|
|
||||||
|
|
@ -42,6 +42,7 @@ namespace Company.WebApplication1
|
||||||
{
|
{
|
||||||
app.UseExceptionHandler("/Error");
|
app.UseExceptionHandler("/Error");
|
||||||
#if (!NoHttps)
|
#if (!NoHttps)
|
||||||
|
// The default HSTS value is 30 days. You may want to change this for production scenarios, see https://aka.ms/aspnetcore-hsts.
|
||||||
app.UseHsts();
|
app.UseHsts();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -42,6 +42,7 @@ namespace Company.WebApplication1
|
||||||
{
|
{
|
||||||
app.UseExceptionHandler("/Error");
|
app.UseExceptionHandler("/Error");
|
||||||
#if (!NoHttps)
|
#if (!NoHttps)
|
||||||
|
// The default HSTS value is 30 days. You may want to change this for production scenarios, see https://aka.ms/aspnetcore-hsts.
|
||||||
app.UseHsts();
|
app.UseHsts();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -42,6 +42,7 @@ namespace Company.WebApplication1
|
||||||
{
|
{
|
||||||
app.UseExceptionHandler("/Error");
|
app.UseExceptionHandler("/Error");
|
||||||
#if (!NoHttps)
|
#if (!NoHttps)
|
||||||
|
// The default HSTS value is 30 days. You may want to change this for production scenarios, see https://aka.ms/aspnetcore-hsts.
|
||||||
app.UseHsts();
|
app.UseHsts();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue