Products

Solutions

Resources

Partners

Community

Blog

About

QA

Ideas Test

New Community Website

Ordinarily, you'd be at the right spot, but we've recently launched a brand new community website... For the community, by the community.

Yay... Take Me to the Community!

Welcome to the DNN Community Forums, your preferred source of online community support for all things related to DNN.
In order to participate you must be a registered DNNizen

HomeHomeOur CommunityOur CommunityGeneral Discuss...General Discuss...User duplicated across multiple portals  - unwanted SSOUser duplicated across multiple portals - unwanted SSO
Previous
 
Next
New Post
9/29/2006 9:33 AM
 

I think it would be great to add a core configuraiton option for the host to optionally turn off duplicate usernames across portals. This can be done in DotNetNuke.Entities.Users.UserController in the AddUser method where there is explicit code to support thes shared user identities.

In the AddUser method, if the user already exists there is special logic to allow the often unwanted SSO. I simply commented out this code in my implementation and returned UsernameAlreadyExists. (this code is based on DNN 3.2.2).

                ' check if username exists in database for any portal
                Dim objVerifyUser As UserInfo = GetUserByUsername(Null.NullInteger, objUser.Membership.Username)
                If Not objVerifyUser Is Nothing Then
                    If objVerifyUser.IsSuperUser Then
                        ' the username belongs to an existing super user
                        Status = UserRegistrationStatus.UserAlreadyRegistered
                    Else
                        ' the username exists so we should now verify the password

                        Common.Globals.SetApplicationName(objVerifyUser.PortalID)
                        '                        If AspNetSecurity.Membership.ValidateUser(objUser.Membership.Username, objUser.Membership.Password) Then
                        '                        ' the specified password matches the password on file
                        '                        UserId = objVerifyUser.UserID
                        '
                        '                        ' check if user exists for the portal specified
                        '                        objVerifyUser = GetUserByUsername(objUser.PortalID, objUser.Membership.Username)
                        '                        If Not objVerifyUser Is Nothing Then
                        '                        ' the user is already registered for this portal
                        '                        Status = UserRegistrationStatus.UserAlreadyRegistered
                        '                        Else
                        '                            ' the user does not exist in this portal - add them
                        '                            Status = UserRegistrationStatus.AddUser
                        '                        End If
                        '                        Else
                        '                           ' not the same person - prevent registration
                        '                           Status = UserRegistrationStatus.UsernameAlreadyExists
                        '                       End If
                        Status = UserRegistrationStatus.UsernameAlreadyExists

WildVoice.com Michael Levy - Are you ready to be heard? WildVoice.com
 
Previous
 
Next
HomeHomeOur CommunityOur CommunityGeneral Discuss...General Discuss...User duplicated across multiple portals  - unwanted SSOUser duplicated across multiple portals - unwanted SSO


These Forums are dedicated to discussion of DNN Platform and Evoq Solutions.

For the benefit of the community and to protect the integrity of the ecosystem, please observe the following posting guidelines:

  1. No Advertising. This includes promotion of commercial and non-commercial products or services which are not directly related to DNN.
  2. No vendor trolling / poaching. If someone posts about a vendor issue, allow the vendor or other customers to respond. Any post that looks like trolling / poaching will be removed.
  3. Discussion or promotion of DNN Platform product releases under a different brand name are strictly prohibited.
  4. No Flaming or Trolling.
  5. No Profanity, Racism, or Prejudice.
  6. Site Moderators have the final word on approving / removing a thread or post or comment.
  7. English language posting only, please.
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out