By default WIF uses a built-in SessionSecurityTokenHandler to serialize the session token to and from the cookie. Behind the scenes this tokenhandler uses the Data Protection API (DPAPI) to protect the cookie material. DPAPI uses a key that is specific to the computer on which it is running in its protection algorithms. For this reason, the default session token handler is not usable in Web farm scenarios because, in such scenarios, tokens written on one computer may need to be read on another computer.
As a solution you can switch the default SessionSecurityTokenHandler by a machine key based alternative:
After doing that, there is one extra step required. The default IIS configuration autogenerates a machine key per application pool.
To generate a specific key and copy it to all server instances on your web farm, remove the checkboxes next to the ‘Automatically generate at runtime’ option and choose Generate Keys from the action menu on the right.
Now you can copy and paste the generated keys to the other servers (or automatically let them replicate if you configured the IIS Web Farm feature).