Vulnerability in EPiServer.Forms

Try our conversational search powered by Generative AI!

caching of friendly url rewrites misses query

The FriendlyUrlRewriter caches urls rewritten. This caching is, however, only done with the path part and the query is not added to any possible output. Thus the following requests will be translated to the same url if they come shortly after each other. /my/page/?q1=a -> /myPage.aspx?q1=a /my/page/?q1=b -> /myPage.aspx?q1=a Clearly a bug. Considering earlier design choices/flaws/bugs, my new url rewrite now reads namespace MyNamespace { class FriendlyUrlRewriteProvider : EPiServer.Web.FriendlyUrlRewriteProvider { public override bool ConvertToInternal(UrlBuilder url, out object internalObject) { internalObject = null; //Don't treat .aspx links if (url.Path.EndsWith(".aspx")) return false; NameValueCollection oldQueryParts = new NameValueCollection(url.QueryCollection); if (base.ConvertToInternal(url, out internalObject)) { //Ensure query string is intact if (oldQueryParts.Count > 0) { foreach (string key in oldQueryParts) url.QueryCollection[key] = oldQueryParts[key]; } return true; } return false; } } } and my web.config in episerver/urlRewrite/providers ...
Oct 16, 2007 12:04
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.