Copied to clipboard

Flag this post as spam?

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


  • Paul Blair 466 posts 731 karma points
    Jan 27, 2010 @ 02:15
    Paul Blair
    0

    Validation of viewstate MAC failed

    has anyone else expereinced the error:

    Validation of viewstate MAC failed. If this application is hosted by a Web Farm or cluster, ensure that <machineKey> configuration specifies the same validationKey and validation algorithm. AutoGenerate cannot be used in a cluster

    using 4.0.3 + integrated pipelines

    On a server successully hosting other Umbraco sites using the same version (and it's not a web farm).

    The error happens when doign a Save & Publish. The problem occurs intermittently but seems to happen most if there is a long delay between viewing the page and doing the save.

    Any ideas?

    Thanks

    Paul

  • Ismail Mayat 4511 posts 10092 karma points MVP 2x admin c-trib
    Jan 27, 2010 @ 09:35
    Ismail Mayat
    1

    Paul,

    I have similar issue recently with non umbraco site and I did some googling and found that adding machineKey tag in web.config with generated validation key fixed the problem. So in your web.config under system.web add

    <machineKey validationKey="addkey"

        decryptionKey="addkey" validation="SHA1" />  

    replace add key with your keys there are online generators on web to create the keys.  I have not seen this issue with umbraco so not sure if this will fix it.

    Regards

     

    Ismail

  • Duc Tran 10 posts 30 karma points
    Oct 14, 2010 @ 14:18
    Duc Tran
    0

    Hi,

    I still receive this error every now and then. I'm using win 2003, Umbraco 4.5.2 and .net 3.5 version - single server. I've done a over 15 sites in Umbraco and the error has always come up. 98% of the tie it runs fine with just the odd viewstate error.

    Was there ever a solution for this? I dont see many post about it. The suggestion above breaks my site,

  • Rick 2 posts 22 karma points
    Nov 17, 2010 @ 02:37
    Rick
    0

    I am having the same issue. It's very intermittent. Is there a solution for this? My host is not a cluster.

  • Johan 188 posts 380 karma points
    Dec 21, 2010 @ 17:30
    Johan
    0

    @Paul: Did you ever find a solution to this? I'm struggling with the exact same issue :(

  • Fergus Davidson 309 posts 588 karma points
    Jan 19, 2011 @ 12:53
    Fergus Davidson
    0

    Hi i have been experiencing this ALOT on my shared hosting. it has been particularly troublesome today for some reason.

    i followed Ismail's advice above, using http://aspnetresources.com/tools/machineKey to generate the key. pasted straight into system.web and seems to have sorted it.

    it is early days yet, but things are certainly better, i'll re-post if things are not sorted

  • Rudi Moritz 8 posts 28 karma points
    Jul 06, 2011 @ 03:18
    Rudi Moritz
    0

    I've got the same problem now, and adding the machineKey doesn't make a difference.

    I created a usercontrol and added it to Umbraco. I did this before, and it was successful. The same usercontrol got just a bit more complex now.

    The error occurs when I select a different item in a dropdownlist of the usercontrol, causing a postback event.

    [Update]

    I continued searching, and found the solution to my problem here: http://forums.asp.net/t/955145.aspx/2/10 ... joteke's tip did the trick for me, i.e. modifying Web.config this way:

    <pages validateRequest="false" enableEventValidation="false" viewStateEncryptionMode ="Never" />

    Rudi

  • Thomas Kahn 602 posts 506 karma points
    Oct 12, 2012 @ 15:57
    Thomas Kahn
    1

    When I got this error it was caused by a faulty character in the name of the node that I created. What happened was that I  copied text from a powerpoint document and and somewhere in this string there was a hidden character (probably a line feed). Then I pasted this text as the name of the node (in this case a file in Media) that I was creating. When i tried to save the node I got the "Validation of viewstate MAC failed" error. After that I couldn't open the media folder where I had created the file.

    This is how I fixed it:

    1. Open up the umbraco database in Microsoft SQL Server Management Studio.
    2. In the table umbracoNode, locate the row with the faulty node you just created. It will probably be the last (highest id).
    3. Change the name (column "text") of the node so the faulty character is removed.
    4. Log in to Umbraco and check that you can access the folder/file again.

    After this I could open the media folder again.

    /Thomas

Please Sign in or register to post replies

Write your reply to:

Draft