Hello
I'm running an ASP.NET 2.0 application on IIS 6 and Windows Server 2003. I'm not using a web farm or garden.I've been getting these errors for a very long time, with some users having to log in each time they visit the site.I've been getting tons of Information events in my Application Event Log with the following message:
Event code: 4005 ,message: Forms authentication failed for the request. Reason: The ticket supplied was invalid.
Not all users have this issues,it happens across a variety of browsers My users the ones that keep getting logged out are noticeably upset and I'm probably losing traffic over the issue.this is the excerpt from my web.config:
i want to know your opinion about this..
thanks for any reply
#2
25-07-2009
johnson22
Member
Join Date: May 2008
Posts: 2,112
Re: Forms authentication failed for the request, the ticket supplied was invalid.
I know this kind or issues arises because of multiple reasons , the most likely is someone trying to login to the forums with an old or expired authentication ticket requiring them to log in, it could genuinely be someone attempting to exploit the forum and create an authentication ticket that will gain them access, this is likely to fail in all cases, generally I would not worry about it unless you're seeing hundreds or thousands every day
#3
25-07-2009
Techguru01
Member
Join Date: Oct 2005
Posts: 2,116
Re: Forms authentication failed for the request, the ticket supplied was invalid.
There are several circumstances that may cause this issue. Each known condition is presented with a short explanation and a possible workaround.IIS 6 will eventually recycle the program pool to keep the health of the application pool. At the instance when the application pool is being recycled, browser requests which can results in an invalid view state error. The cure in this case is to adjust the settings on the application pools so that recycling is less likely to occur at peak periods. This issue denotes a bug since the application pool is supposed to gracefully handle this condition.
#4
25-07-2009
deveritt
Member
Join Date: Apr 2008
Posts: 2,528
Re: Forms authentication failed for the request, the ticket supplied was invalid.
Since the View State is saved in a hidden field on a Web page, it is more likely to tamper when data is being transferred between the client and the server.So in order to make View State more secure, ASP.NET validates View State to confirm that it came from the correct page. I think from the error message, it's obviously caused by the expired time of the ticket. From the code we can see that you set the cookie as long as possible, but if the expired time of the ticket is short, the ticket is invalid in a short time. You can check that.If ASP.NET cannot validate View State, ASP.NET returns a message to the client browser that states that "viewstate is invalid for this page and might be corrupted." However, the message does not describe why View State is not valid.
Thanks to the authorities who wrote this post. Of the many posts I've seen, this one is the most standard. If you want, you can read this post ( https://kodlogs.net/327/forms-authentication-failed-reason-the-ticket-supplied-has-expired ) as well as another post
ReplyDelete