Avatar of ajacoa
ajacoa
 asked on

How do I use DotNetNuke Membership Authentication from Another Application?

I have a standard DNN installation with NB_Store.  I have a separate application that runs in a different virtual directory, but has access to the DNN database.  This app currently uses default "AspNetSqlMembershipProvider" authentication.   This application uses c# code "Membership.ValidateUser(sUserName,sPassword)" to determine if the user is a member.
I want this application to use the DNN authentication system/database.  How do I do this?  Is it as simple as modifying the app's web.config file?  Do I simply add a <connectionStrings> for the DNN SQL server?  How would I modify the "<membership defaultProvider=…" section since I don't see the equivalent in the DNN Web.Config?
ASP.NETC#.NET Programming

Avatar of undefined
Last Comment
ajacoa

8/22/2022 - Mon
ASKER CERTIFIED SOLUTION
Mlanda T

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
GET A PERSONALIZED SOLUTION
Ask your own question & get feedback from real experts
Find out why thousands trust the EE community with their toughest problems.
ajacoa

ASKER
MlandaT,  Thanks for the link, it was helpful.
So it appears that if I just want to validate the user, it is as easy as modifying my ASP.NET app's web.config file so my app points to DNN's Membership provider.
However if I want to use Roles in my App (I currently don't), it may be substantially more difficult.
This is because DNN uses the standard ASP.NET Membership provider, but not the ASP.NET Role provider. Correct?
Mlanda T

Ajacoa... unfortunately, I am not too familiar with the DNN roles. I'd assume that it still uses the same. Will you need to use the roles in your app at a later stage?
ajacoa

ASKER
Single responder.
Experts Exchange has (a) saved my job multiple times, (b) saved me hours, days, and even weeks of work, and often (c) makes me look like a superhero! This place is MAGIC!
Walt Forbes