internal void SetXRobotsTagHeader(HttpResponseBase response, NWebsecContext nwebsecContext)
        {
            nwebsecContext.XRobotsTag = WebConfig.XRobotsTag;
            var result = _headerGenerator.CreateXRobotsTagResult(WebConfig.XRobotsTag);

            _headerResultHandler.HandleHeaderResult(response, result);
        }
        internal void SetXRobotsTagHeader(IHttpContextWrapper httpContext, NWebsecContext nwebsecContext)
        {
            nwebsecContext.XRobotsTag = WebConfig.XRobotsTag;
            var result = _headerGenerator.CreateXRobotsTagResult(WebConfig.XRobotsTag);

            _headerResultHandler.HandleHeaderResult(httpContext, result);
        }
Esempio n. 3
0
        public void SetXRobotsTagHeader(HttpContext context)
        {
            var config = _headerConfigurationOverrideHelper.GetXRobotsTagWithOverride(context);

            if (config == null)
            {
                return;
            }

            var oldConfig = _contextConfigurationHelper.GetXRobotsTagConfiguration(context);

            var result = _headerGenerator.CreateXRobotsTagResult(config, oldConfig);

            _headerResultHandler.HandleHeaderResult(context.Response, result);
        }