Here is my forms authentication section from my web.config
<authentication mode="Forms">
<forms name="security" path="/" loginUrl="default.aspx" protection="All" timeout="360" />
</authentication>
<authorization>
<deny users="?" />
</authorization>
For some reason after change to .net 4 as my target, people have to login twice before my form authentication redirects now. Has anyone else run into this.
Also my login is in the homepage so I tried the below thinking I just need to make my login page public, but it did not work. Anyone else have this problem?
Also I noticed that soon as I visit my homepage I get this in the url default.aspx?ReturnUrl=%2f, if I remove the ReturnUrl parameter, it then works to login first time. But if ReturnUrl is in querystring I have to login twice the first time visiting the site.
default.aspx?ReturnUrl=%2f
So I added the page to public access in my locations and this didn't help..
<location path="default.aspx">
<system.web>
<authorization>
<allow users="*" />
<deny users="?" />
</authorization>
</system.web>