Sharing owin cookies with MVC 5?

I am making an SSO application with user management in MVC 5, but I cannot share a cookie between applications, for example

http: // sso http: // app

different sites in IIS, I think it is something like a cross domain, so in app2, when I have something like this in startup.auth

app.UseCookieAuthentication(new CookieAuthenticationOptions { CookieName = "sharedcookie", CookieDomain = "SSO", CookieHttpOnly = false, //CookieDomain = "localhost", AuthenticationType = DefaultAuthenticationTypes.ExternalCookie, LoginPath = new PathString("/Account/Login"), Provider = new CookieAuthenticationProvider { external login to your account. OnValidateIdentity = SecurityStampValidator.OnValidateIdentity<ApplicationUserManager, ApplicationUser>( validateInterval: TimeSpan.FromMinutes(30), regenerateIdentity: (manager, user) => user.GenerateUserIdentityAsync(manager)) } }); 

UPDATE: thanks to Chris Pratt for answering that there is no way to do this, which will lead me to another question that can I share a cookie between

name1.domain.com/app1 and name2.domain.com/app2

With owin

+2
cookies asp.net-mvc owin shared single-sign-on
source share
1 answer

I found this article about the draft code today, when I was interested in the same thing, and not 100% confident, but it definitely seems possible to me.

Part 1 - Design: http://www.codeproject.com/Articles/106439/Single-Sign-On-SSO-for-cross-domain-ASP-NET-applic

Part 2 - Implementation: http://www.codeproject.com/Articles/114484/Single-Sign-On-SSO-for-cross-domain-ASP-NET-appl

Assume that this is not really a cookie sharing between domains, but a use of the SSO user management web service (which seems fine to me!)

NB: I know that the links only answers are discouraged, but these articles are huge, anyone who wants to tell me how to do it properly is welcome :)

+1
source share

All Articles