title: How to disable the antiforgery token check in ASP.NET MVC Core 2
body: <p>I am trying to avoid "AntiForgery" checking as it always fails when hosted from the 3rd party server. I am using ASP.NET Core 2.0 MVC application.</p>
  
  <p>I added this option in the <code>ConfigureServices</code> function:</p>
  
  <pre><code>services
      .AddMvc()
      .AddRazorPagesOptions( options =&gt;
      {
          options.Conventions.AuthorizeFolder("/Account/Manage");
          options.Conventions.AuthorizePage("/Account/Logout");
          options.Conventions.ConfigureFilter(new IgnoreAntiforgeryTokenAttribute());
      } );
  </code></pre>
  
  <p>But still I am getting this exception.</p>
  
  <blockquote>
    <p>System.InvalidOperationException: The antiforgery token could not be decrypted.<br>
    System.Security.Cryptography.CryptographicException: The key {6fb328e7-4808-4b5d-b7dc-870d126e5ca4} was not found in the key ring.</p>
  </blockquote>
  
  <p>Am I missing anything ?</p>