Try our conversational search powered by Generative AI!

Log in into chat application using default login

Vote:
 

Hi,

I want to login into my chat application which is a javascript app from the logged in credentials of the Episerver. I was just having a look into episerver alloy app. I was not able to find the login page. Please how you help me on achieving this. Thanks is advance!!!!

#143605
Jan 27, 2016 15:25
Vote:
 

for most EPiServer sites you can always log in using the url:

[domain]/util/login.aspx

To get the current user and check authentication:

EPiServer.Security.PrincipalInfo.CurrentPrincipal.Identity.IsAuthenticated

and

EPiServer.Security.PrincipalInfo.CurrentPrincipal.Identity.Name

You can use the second to log in the current user to your js app...

#143606
Jan 27, 2016 15:36
Vote:
 

Thanks for the reply daniel. I am the alloy app in my visual studio . I was not able to find the login.aspx page in the Solution explorer. I am using active directory to login, I need username and password of the user to autologin into my chat account. Would be suggest me a way how to achieve it.

#143623
Jan 28, 2016 7:10
Vote:
 

Hi i am using ejabberg server with converse.js, i need to pass the CurrentPrincipal for authentication.

https://conversejs.org/docs/html/configuration.html#prebind-url

This is how is need to achieve it but how to pass SID and RID.

#143628
Jan 28, 2016 8:05
Vote:
 

I would probably do a custom login page for EPi. There are plenty of guides of how to do that. It's pretty easy...

After validating credentials I would store a unique id in session for the user that I can then use as SID and pass to ejabberg server. 

For RID I would probably generate a unique id for each request in the ActionFilter that is used to set the overall layout for mvc / masterpage for webforms. 

#143634
Jan 28, 2016 10:02
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.