{"action":"created","issue":{"url":"https://api.github.com/repos/Sustainsys/Saml2/issues/849","repository_url":"https://api.github.com/repos/Sustainsys/Saml2","labels_url":"https://api.github.com/repos/Sustainsys/Saml2/issues/849/labels{/name}","comments_url":"https://api.github.com/repos/Sustainsys/Saml2/issues/849/comments","events_url":"https://api.github.com/repos/Sustainsys/Saml2/issues/849/events","html_url":"https://github.com/Sustainsys/Saml2/issues/849","id":274930555,"number":849,"title":"Cookie not set for multiple SAML IDP","user":{"login":"netachar05","id":33759222,"avatar_url":"https://avatars2.githubusercontent.com/u/33759222?v=4","gravatar_id":"","url":"https://api.github.com/users/netachar05","html_url":"https://github.com/netachar05","followers_url":"https://api.github.com/users/netachar05/followers","following_url":"https://api.github.com/users/netachar05/following{/other_user}","gists_url":"https://api.github.com/users/netachar05/gists{/gist_id}","starred_url":"https://api.github.com/users/netachar05/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/netachar05/subscriptions","organizations_url":"https://api.github.com/users/netachar05/orgs","repos_url":"https://api.github.com/users/netachar05/repos","events_url":"https://api.github.com/users/netachar05/events{/privacy}","received_events_url":"https://api.github.com/users/netachar05/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":9,"created_at":"2017-11-17T16:58:04Z","updated_at":"2017-11-19T11:52:18Z","closed_at":null,"author_association":"NONE","body":"Our application is authenticated for multiple Shibboleth IDP using KentorAuthServices.  Challenge works fine but, HttpContext.Current.GetOwinContext().Authentication.AuthenticateAsync(DefaultAuthenticationTypes.ExternalCookie)  fails to return the principal if multiple identity providers are configured.  \r\n\r\nI found that if it is a single provider, the request will have a cookie .AspNet.ExternalCookie and has a proper value and authenticates without any issue.\r\n\r\nIf multiple identity providers are added, the cookie name is Kentor.Gr-lOTMKSNFn4vQ0U-eNsfNVp8T1pbadbJiT5jXkUrgn8R7P8YYyl0_Z and the value ends with ... (3VTfiCKc2mfIcxU1On0Yljz_uh2VvDD5jHGX26E4UNJeKpw_THDZWgZQjN4bB9obSdl0z7FnPKj61pAQ-n5RVXrPBhY4V7-Ky1krJaZX7c-KF41F_TL0owvb-JPl3Gnc6T6puLFp9Wo1T0BnwtYjP_o5WBaKgWcd1SaAROoqk2vIn2Um6EZX22yMRHbzb2naMtJK4GUCuU6wZSBLcyJvhrO0v8o-d1t-jgoetZjqCmElcnj9clW3CfQ2WTZj8U80TjhzRw..)  which fails the authentication and return null.\r\n\r\nHow can we handle this?\r\n\r\n"},"comment":{"url":"https://api.github.com/repos/Sustainsys/Saml2/issues/comments/345510796","html_url":"https://github.com/Sustainsys/Saml2/issues/849#issuecomment-345510796","issue_url":"https://api.github.com/repos/Sustainsys/Saml2/issues/849","id":345510796,"user":{"login":"AndersAbel","id":4894558,"avatar_url":"https://avatars1.githubusercontent.com/u/4894558?v=4","gravatar_id":"","url":"https://api.github.com/users/AndersAbel","html_url":"https://github.com/AndersAbel","followers_url":"https://api.github.com/users/AndersAbel/followers","following_url":"https://api.github.com/users/AndersAbel/following{/other_user}","gists_url":"https://api.github.com/users/AndersAbel/gists{/gist_id}","starred_url":"https://api.github.com/users/AndersAbel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/AndersAbel/subscriptions","organizations_url":"https://api.github.com/users/AndersAbel/orgs","repos_url":"https://api.github.com/users/AndersAbel/repos","events_url":"https://api.github.com/users/AndersAbel/events{/privacy}","received_events_url":"https://api.github.com/users/AndersAbel/received_events","type":"User","site_admin":false},"created_at":"2017-11-19T11:52:18Z","updated_at":"2017-11-19T11:52:18Z","author_association":"OWNER","body":"@netachar05 You need to set separate module path's for each instance as well. Even though you have different public origins, the first middleware instances will always be triggered. If you enable logging, I'm sure you'll see a message that the idp is unknown."}}
{"actor":{"display_login":"AndersAbel"}}