Currently we are creating virtual user in Sitecore (9.0.2) database once user is authenticated with backend API as shown below
Sitecore.Security.Authentication.AuthenticationManager.BuildVirtualUser("extranet\\" + Email, true);
We are checking the user is authenticated or not by using below code
Now the problem is, we are adding one more website within same App service that will use same code. Only difference is that site1 and site2 have different virtual directory as shown below
We need to authenticate user against each site separately. Means one user can able to login site1 and site 2 from single browser.
Currently what is happening is that if a user logged into site 1 user is also logged into site 2. this should not happen.
Your help is most welcome.