0
votes

I am receiving the error message below:

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

After lots of search, I found this document https://support.microsoft.com/en-us/kb/2915218

In Above document i found below section

Appendix A: How to generate a machineKey element

In this section, there is a function which generate <machineKey> but i don't know where to put this code in my application and how to call this function.

1
<machinekey> should be kept in web.config fileGuruprasad J Rao

1 Answers

1
votes

Generate machine key using link

<machineKey
validationKey="56AB7132992003EE87F74AE4D9675D65EED8018D3528C0B8874905B51940DEAF6B85F1D922D19AB8F69781B2326A2F978A064708822FD8C54ED74CADF8592E17"
decryptionKey="A69D80B92A16DFE1698DFE86D4CED630FA56D7C1661C8D05744449889B88E8DC"
validation="SHA1" decryption="AES" />

The <machineKey> should be put inside <system.web> section.

Follow this link