Cookie sharing under cluster, must be set machinekey

Source: Internet
Author: User

This section allows you to set a server-specific key for encrypting data and creating a digital signature. Asp. NET automatically uses it to protect form validation cookies, which you can also use for Protected view state data. At the same time, this key is also used to validate out-of-process session state providers. If you are using a Web cluster and running the same application on multiple computers, if the request to the page is handled by one computer, and the page postback is processed by another computer, the second server cannot decrypt the view state and form cookie from the first server. This problem occurs because the two servers use different keys. To solve this problem, you must explicitly define this key in the Machine.config file:


Cookie sharing under cluster, must be set machinekey

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: 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.