Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at

  • Pavel 5 posts 86 karma points
    May 03, 2017 @ 18:22

    System.Web.HttpRequest does not have the CleanForXss definition

    Version 7.6 downloaded as zip and unziped to folder. An error is generated in Visual Studio when you build a Web site: System.Web.HttpRequest does not have the CleanForXss definition, and no CleanForXss extension method has been found that would accept the first System.Web.HttpRequest argument (does not use the use directive or build link?)

    The error is in Umbraco / Users / PermissionEditor.asmx at line 30 UserId: <% = Request.CleanForXss ("id")%>,

    This can be fixed: UserId: <% = Request.QueryString ["id"]%>,

    In release 7.6RC was Request.QueryString ["id"] and in release 7.6 already Request.CleanForXss ("id")

    How can I fix it correctly. or I should ignore this mistake

    Is it really interesting that it does not make anyone a problem? It was a change between RC and Release versions, which should be exceptional.

  • Jason 1 post 71 karma points
    May 05, 2017 @ 14:23

    Am getting the same issue. Did you resolve it?

  • Pavel 5 posts 86 karma points
    May 07, 2017 @ 11:30

    Not yet. I still ignore this error.

    The error may not occur if the project was compiled in Visual Studio by default.

    I only use the expanded zip into the folder.

    Then I open the project in visual studio as a website.

    This is not a compilation but just a build check.

    Maybe not just an available library.

    I'll think of it until some mistake is made in the umbraco backoffice.

    Maybe in the next version.

  • Jan Bílek 15 posts 187 karma points
    May 07, 2017 @ 15:18
    Jan BĂ­lek


    I've run into this issue as well. It prevents you from setting user permissions from the backoffice. Prompting the QueryString parameter fixes the issue. However, the real solution is to add this import to the begining of PermissionEditor.aspx file:

    <%@ Import Namespace="Umbraco.Web" %>
  • Pavel 5 posts 86 karma points
    May 07, 2017 @ 15:52

    Thank you, me and the others with this mistake.

    I was expecting such a solution.

    This change was too quick.

  • Q-ten 16 posts 116 karma points
    May 31, 2017 @ 06:01

    Thank you, I had this problem too.

    We're using Umbraco Cloud and the Auto Update changed the line

    userId: <%=Request.QueryString["id"] %>,


    userId: <%=Request.CleanForXss("id") %>,

    in the upgrade to 7.5.14


    <%@ Import Namespace="Umbraco.Web" %>

    to the top of the file fixed it for us.


  • MuirisOG 382 posts 1283 karma points
    Jul 21, 2017 @ 10:14


    Adding the import fixed this issue for me.

    <%@ Import Namespace="Umbraco.Web" %>

    Many thanks for your solution.


  • Murray Roke 486 posts 908 karma points c-trib
    Jul 26, 2017 @ 22:59
    Murray Roke

    This seems to be fixed in this commit:

    So 7.6.1 and greater should not have this issue.

Please Sign in or register to post replies

Write your reply to: