title: Unable to validate data. at System.Web.Configuration.MachineKeySection.GetDecodedData
body: <p>I have several websites which get approximately 3000 pageviews in total per day, and I get this viewstate error roughly 5-10 times per day, caught in global.asax:</p>
  
  <p>System.Web.HttpException: Unable to validate data. at System.Web.Configuration.MachineKeySection.GetDecodedData(Byte[] buf, Byte[] modifier, Int32 start, Int32 length, Int32&amp; dataLength) at System.Web.UI.ObjectStateFormatter.Deserialize(String inputString)</p>
  
  <p>I have tried:</p>
  
  <ul>
  <li>hard-coding the machine key in web.config for all websites</li>
  <li>hard-coding the machien key in machine.config</li>
  <li>adding items to the pages section of the web.config for all websites.</li>
  </ul>
  
  <p>Machine key looks like:</p>
  
  <pre><code>&lt;machineKey validationKey="key goes here" decryptionKey="key goes here" validation="SHA1" decryption="AES" /&gt;
  </code></pre>
  
  <p>Pages section looks like:</p>
  
  <pre><code>&lt;pages renderAllHiddenFieldsAtTopOfForm="true" validateRequest="false"  enableEventValidation="false" viewStateEncryptionMode="Never"&gt;
  </code></pre>
  
  <p>The errors are not related to application pool recycling as best I can tell, as the pool is set to recycle at every 100,000 requests. I am not running a web farm or web garden. Quite often I get two or three of these errors in a row, as if a user is getting an error, going back, and then clicking the link again.</p>
  
  <p>Anyone have any ideas?</p>