Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Azure AD B2C login with Sitecore - Not getting cookies #14

Open
dkchittimilla opened this issue Sep 21, 2018 · 4 comments
Open

Azure AD B2C login with Sitecore - Not getting cookies #14

dkchittimilla opened this issue Sep 21, 2018 · 4 comments

Comments

@dkchittimilla
Copy link

dkchittimilla commented Sep 21, 2018

Hi @BasLijten ,

Currently I am working on Sitecore 9 and we have a requirement to include Azure B2C authentication mechanism. Setup wise everything is fine, on successful login we are redirecting back to sitecore site pages, but I am not receiving .AspNet.Cookies cookie. Not sure what the problem is. Can you please guide me.

Regards,
Dilip Kumar

@BasLijten
Copy link
Owner

Did you use this solution, or the Sitecore 9 federated authentication solution?

@dkchittimilla
Copy link
Author

Did you use this solution, or the Sitecore 9 federated authentication solution?

Thanks for the update @BasLijten . I am not using Sitecore 9 federated authentication, but used some part of the code to validate the cookies. i.e.

if (ctx.Cookies != null && ctx.Cookies[“.AspNet.Cookies”] != null)
{
var cookie = ctx.Cookies[“.AspNet.Cookies”];

But for me cookie are not coming and hence this piece of code is not working. Can you please suggest me what may be the problem.

@BasLijten
Copy link
Owner

I really do not understand what kind of solution or middleware you are currently using. I know that there might be some issues with this module and Azure AD B2C, which don't exist with the Sitecore 9 implementation. That might cause your issue?

@dkchittimilla
Copy link
Author

dkchittimilla commented Sep 21, 2018

I am trying to use a fair simple authentication using Azure AD B2C where from my application I am redirecting properly to B2C login screen and after successful login, I am coming back to the redirect URI what I configured. But after redirecting to my application, I am not able to find the cookies. Just wondering if it is due to any configurations?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants