Static->static referer policy

main
Inga 🏳‍🌈 14 years ago
parent b85936a3ee
commit f8144babbf
  1. 2
      Builder/IISMainHandler/build.txt
  2. 2
      Builder/IISUploadHandler/build.txt
  3. 2
      IISMainHandler/MainHandler.cs

@ -15,7 +15,7 @@ namespace FLocal.IISHandler {
private void doProcessRequest(HttpContext httpcontext) {
Uri referer = httpcontext.Request.UrlReferrer;
if(referer != null && referer.PathAndQuery.StartsWith("/static")) {
if(referer != null && referer.PathAndQuery.StartsWith("/static") && !httpcontext.Request.Path.StartsWith("/static") {
throw new HttpException(403, "You have come from the static page '" + referer + "'");
}

Loading…
Cancel
Save