Link to home
Create AccountLog in
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?
ASKER CERTIFIED SOLUTION
Avatar of Mlanda T
Mlanda T
Flag of South Africa image

Link to home
membership
Create an account to see this answer
Signing up is free. No credit card required.
Create Account
Avatar of ajacoa
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?
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?
Avatar of ajacoa

ASKER

Single responder.