YAFLogo

plyafnet
  • plyafnet
  • 52.6% (Neutral)
  • YAF Forumling Topic Starter YAF Version: YAF.NET4.0.0. RC3
24 days ago
For one forum board which is integrated with an Azure website where users are already logged in via ADB2C (or Active Directory, also called Entra ID), I want users to be able to use the forum automatically (because they are already logged in), using their ADB2C username.

Is that possible, and if so, how?

[color=var(--bs-body-color)][font=system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", "Noto Sans", "Liberation Sans", Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji"]Many thanks![/font][/color]

Sponsor
tha_watcha
  • tha_watcha
  • 100% (Exalted)
  • YAF.NET Project Lead 🤴 YAF Version: 4.0.0 rc 2
23 days ago
Yes it is possible you would only need to replace the UserStore and RolesStore in the ASP.NET Identity provider. You dont even need to modify the source. You can override it from an external dll.

You can see how it works in the dnn module

https://github.com/YAFNET/YAFNET-DNN/blob/master/yaf_dnn/Components/Integration/RoleStore.cs 

https://github.com/YAFNET/YAFNET-DNN/blob/master/yaf_dnn/Components/Integration/UserStore.cs 

plyafnet
  • plyafnet
  • 52.6% (Neutral)
  • YAF Forumling Topic Starter YAF Version: YAF.NET4.0.0. RC3
15 days ago

Yes it is possible you would only need to replace the UserStore and RolesStore in the ASP.NET Identity provider. You dont even need to modify the source. You can override it from an external dll.

You can see how it works in the dnn module

https://github.com/YAFNET/YAFNET-DNN/blob/master/yaf_dnn/Components/Integration/RoleStore.cs 

https://github.com/YAFNET/YAFNET-DNN/blob/master/yaf_dnn/Components/Integration/UserStore.cs 

Originally Posted by: tha_watcha 

Sorry if I'm being slow/dense, but if I wanted to replace the source of UserStore/RolesStore what would I replace it with?

And if I were doing this within say the YAF.NET-SqlServer solution, presumably the Account folder within Pages would also not be needed, since ADB2C will be providing all the login/forgot password etc forms?