Issue using ASP.NET Core Identity Auth with Angular SPA

I’m attempting to use ASP.NET Core Identity Auth with ServiceStack when developing a new project. In previous projects I would use credentials and JWT for the session state on the web interface.

However, on reading a few of the documents, it seems that I shouldn’t use JWT with this new solution and should rely on the session cookies.

My register and signin endpoints work fine, I can successfully login and move around the site when logged in. My issue is that when I refresh the browser, the session is lost and I have to login again. I’ve even tried the rememberMe flag and that has no effect. I can see the ss-opt cookie being set, no sign of ss-tok (I assume this is due to the ASP related cookie I can see being set?)

I’m using Angular if that makes any difference and I am currently testing in development mode.

If you’re using ASP .NET Core’s default Application Cookie Authorization then the Session should be established across browser refreshes.

I’d look at the other vue-spa or react-spa for Authorization configuration.

Ok I’ll investigate further.

I’ve used the same configuration as the vue-spa example so the issue must be in the Angular code.

Thanks for confirming.