Asp. NET in IE10 can not judge the user logged in and the session lost problem solving method

Source: Internet
Author: User
Tags session id
Today found in IE10 in my company's website, click on the other menu, the page will always automatically re-exit to the login page, after the check found that IE10 sent HTTP headers, and. AUTH cookies are fine, but using the form validation mechanism (FormsAuthentication) You cannot tell if the user is logged in and the saved session is always lost.

After the verification that this is the ASP. 2.0,3.5 and 4.0, because these versions do not recognize the User-agent header string of IE10, the version of the user's browser is not recognized, which leads to the failure of the specific function of ASP. It is considered that the browser does not support the cookie function, does not handle the code related to cookies, and so on, so that the session ID returned by the server is not saved, resulting in loss etc.

This issue has been officially confirmed by Microsoft, is a bug IE10, also released two hotfix specifically to repair the problem, you encounter the same problem, you can refer to the following instructions:
Kb2600088:hotfix for ASP. NET in the Microsoft.NET Framework 4.0 [English]
Kb2608565:hotfix for ASP. NET Framework 3.5.1 [English]
Kb2600100:hotfix for ASP. NET Framework 3.5 SP1 and. NET Framework 2.0 SP2 [English]
A simple workaround is to add a browser definition file (browser definition files) to the Web site root directory

The steps are as follows:
1. Add a "App_Browsers" folder
2. Add a "*.browser" suffix to the file, such as Ie10.browser.
3. Add the contents of the file as follows:

<browsers> <browser refid= "Default" > <capabilities><!--to avoid wrong detections of e.g. IE10--> ; <capability name= "Cookies" value= "true"/> <capability name= "ecmascriptversion" value= "3.0"/> </ Capabilities> </browser> </browsers>


Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.