U6: SpaFallback-SEO: Website:NoIndex (X-Robots-Tag), robots.txt, sitemap.xml en KnownPaths (echte 404)
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -63,6 +63,10 @@ public static class CmsHost
|
||||
{
|
||||
builder.Services.AddCmsWebsite(builder.Configuration);
|
||||
}
|
||||
else
|
||||
{
|
||||
builder.Services.AddCmsSpaSeo(builder.Configuration);
|
||||
}
|
||||
|
||||
// Registered BEFORE module services: modules must not configure Data Protection themselves,
|
||||
// because a later registration would override this persistent key store (see
|
||||
@@ -115,6 +119,13 @@ public static class CmsHost
|
||||
// which is almost all of the HTML this host serves.
|
||||
app.UseCmsSecurityHeaders();
|
||||
|
||||
// SpaFallback sites: X-Robots-Tag on test hosts and generated robots.txt / sitemap.xml. After the
|
||||
// security headers (so these answers carry them) and before the static files short-circuit.
|
||||
if (options.WebsiteMode == WebsiteMode.SpaFallback)
|
||||
{
|
||||
app.UseCmsSpaSeo();
|
||||
}
|
||||
|
||||
app.UseRateLimiter();
|
||||
|
||||
// 6. Configure Pipeline
|
||||
|
||||
Reference in New Issue
Block a user