Question : Validation of viewstate MAC failed? How I fix it?

I am getting an exception, but I dont know how to fix it, and why I am getting this error.


strMessage=

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.

_____________________________________

strInnerException=

System.Web.UI.ViewStateException: Invalid viewstate.
Client IP: 89.130.13.104
Port: 4938
User-Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0; MRSPUTNIK 2, 3, 0, 104; MRA 5.6 (build 03402); .NET CLR 2.0.50727; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729)
ViewState: /wEPDwUKMTA3MzA5OTI2OQ9kFgJmD2QWAgIDD2QWCAIGD2QWUAIBDw8WBh4EVGV4dAUPSSBnb3QgYSBmZWVsaW5nHgtOYXZpZ2F0ZVVybAVxLi4vbW9zdHJhci5hc3B4P2NhbmNpb249b2ZfSV9nb3RfYV9mZWVsaW5nX0JsYWNrX0V5ZWRfUGVhY2UmZmVhdHVyZT1SZWxfNDFfVm9pc19TdXJfVG9uX0NoZW1pbl9MZXNfQ2hvcmlzdGVzX2FsbDAeB1Zpc2libGVnZGQCAw8PFgYfAAUQQmxhY2sgRXllZCBQZWFjZR8BBScuLi9hcnRpc3RhLmFzcHg/bm9tYnJlPUJsYWNrIEV5ZWQgUGVhY2UfAmdkZAIFDw8WBh8ABS5QaXJhdGVzIG9mIHRoZSBDYXJpYmJlYW4gKFBpcmF0YXMgRGVsIENhcmliZSApHwEFfy4uL21vc3RyYXIuYXNweD9jYW5jaW9uPWtuX1BpcmF0ZXNfb2ZfdGhlX0NhcmliYmVhbl8oUGlyYXRhc19EZWxfQ2FyaWJlXykmZmVhdHVyZT1SZWxfNDFfVm9pc19TdXJfVG9uX0NoZW1pbl9MZXNfQ2hvcmlzdGVzX2FsbDEfAmdkZAIHDw8WBh8ABRJQaXJhdGFzIERlbCBDYXJpYmUfAQUpLi4vYXJ0aXN0YS5hc3B4P25vbWJyZT1QaXJhdGFzIERlbCBDYXJpYmUfAmdkZAIJDw8WBh8ABRxCaWcgR2lybCAoWW91IEFyZSBCZWF1dG... ---> System.Web.HttpException: Unable to validate data.
at System.Web.Configuration.MachineKeySection.GetDecodedData(Byte[] buf, Byte[] modifier, Int32 start, Int32 length, Int32& dataLength)
at System.Web.UI.ObjectStateFormatter.Deserialize(String inputString)
--- End of inner exception stack trace ---

_____________________________________

strStackTrace=

at System.Web.UI.ViewStateException.ThrowError(Exception inner, String persistedState, String errorPageMessage, Boolean macValidationError)
at System.Web.UI.ViewStateException.ThrowMacValidationError(Exception inner, String persistedState)
at System.Web.UI.ObjectStateFormatter.Deserialize(String inputString)
at System.Web.UI.ObjectStateFormatter.System.Web.UI.IStateFormatter.Deserialize(String serializedState)
at System.Web.UI.Util.DeserializeWithAssert(IStateFormatter formatter, String serializedState)
at System.Web.UI.HiddenFieldPageStatePersister.Load()
at System.Web.UI.Page.LoadPageStateFromPersistenceMedium()
at System.Web.UI.Page.LoadAllState()
at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
at System.Web.UI.Page.ProcessRequest(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
at System.Web.UI.Page.ProcessRequest()
at System.Web.UI.Page.ProcessRequestWithNoAssert(HttpContext context)
at System.Web.UI.Page.ProcessRequest(HttpContext context)
at ASP.mostrar_aspx.ProcessRequest(HttpContext context)
at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)



I already have the code this:


  <system.web>
<pages enableViewStateMac="false" />

In my web.config. but it still happens.

Any help?

Answer : Validation of viewstate MAC failed? How I fix it?

This is the issue with the .net framework

To get the fix you will have to contact Microsoft at 800 936-5800 (select option 3) to open a case and request Fix number KB 361949

For details check
http://social.msdn.microsoft.com/Forums/en-US/vstswebtest/thread/0f143e24-65e7-4f44-8d64-a8f920f410af
Random Solutions  
 
programming4us programming4us