Forms Authentication cookie is getting created before Login
<p>I am maintaining an application and when I open the Login page (NOT login), the Forms Authentication cookie gets created. I have checked in the Fiddler to confirm. On decrypting the cookie, it shows its an empty/junk cookie with values:</p>

<blockquote>
  <p>Name="-1" IsAuthenticated= True</p>
</blockquote>

<p>I have checked the code to see if there is any place where we are creating the cookie manually however could not find so. I have commented the code in the pageLoad event of the Login page and also the code for Application_AcquireRequestState, FormsAuthentication_OnAuthenticate, Application_AuthenticateRequest events in Global.asax file. But still the cookie gets created. </p>

<p>The Web.Config entry for the Forms Authentication is:</p>

<pre><code>&lt;authentication mode="Forms"&gt;
&lt;forms name="appNameAuth" path="/" loginUrl="~/Login.aspx" timeout="30" defaultUrl="~/Home.aspx" protection="Validation" slidingExpiration="true"&gt;
&lt;/forms&gt;
&lt;/authentication&gt;
&lt;authorization&gt;
&lt;deny users="?" /&gt;
&lt;/authorization&gt;
</code></pre>

<p>Please suggest what other setting can cause the Forms Auth cookie to get created even before the login.</p>

<p>Thanks for your help!</p>

<p>Regards,
Arjun</p>
