I\'m working on a site that has a requirement to share session between a cms application and an online store application on the same domain eg.
mydomain.com
Persist all session data on the SQL-server, using the session-ID as key. Then use a cookie containing the session-ID that points to .mydomain.com
so it will be available on both sub-domains.
This article at 15 seconds covers the subject and even shows a technique to share sessions across completely different domains.
It appears the issue we were having was that the session cookie domain was being being set differently on the 2 applications. This meant that each application generated it's own sessionId.
We added
<httpCookies domain=".ourdomain.co.uk" />
to our web.config and that seems to have solved it. Thanks for hte help, hope this helps someone else in the future.