System.Web.HttpException:验证视图状态MAC失败.
我正在asp.net中开发Web应用程序
我从最近两天开始面临问题.虽然我在web.config文件中做了一些更改.
我遇到以下错误:
System.Web.HttpException:验证视图状态MAC失败.
完整说明:
验证视图状态MAC失败.如果此应用程序由Web场或群集托管,请确保< machinekey>配置指定相同的validationKey和验证算法.自动生成不能在群集中使用.
我确实在互联网上搜索,但没有找到解决方案.
谁能帮我吗
Hi,
I m developing web application in asp.net
I m facing problem from last two days. while i have some changes in web.config file.
I have got the following error:
System.Web.HttpException: Validation of viewstate MAC failed.
full discription:
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.
I did search on internet, but I am not getting the solution.
Can anyone help me please
thanks in advance.
将enableEventValidation设置为false,将viewStateEncryptionMode设置为Never,如下所示:
Set enableEventValidation to false and viewStateEncryptionMode to Never as follows:
<pages enableeventvalidation="false"
viewstateencryptionmode="Never">
您是否尝试过MSDN文章@ http ://blogs.msdn.com/b/tom/archive/2008/03/14/validation-of-viewstate-mac-failed-error.aspx [
Did you try the MSDN article @ http://blogs.msdn.com/b/tom/archive/2008/03/14/validation-of-viewstate-mac-failed-error.aspx[^]