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

HomeHomeDNN Open Source...DNN Open Source...Provider and Extension ForumsProvider and Extension ForumsAuthenticationAuthenticationnot automatic login, but okay going to windowssigninnot automatic login, but okay going to windowssignin
Previous
 
Next
New Post
4/3/2009 1:09 PM
 

Honestly, 99.9% of the time it will work with zero changes to the web.config file.  

Try this out:
- Rename your web.config so you have a backup.
- Take a copy of the release.config file, rename it to web.config
- Update that file with your database and key information so DNN runs.
- Install the AD provider again (which will make it's own necessary modification to the web.config file).
- Start DNN and test it.

This works almost every time, with no futher modifications.

(I have a sneaking suspicion that a good percentage of the people having problems with AD authentication caused those problems themselves by editing the web.config and making setting changes that are unecessary.)

 
New Post
4/3/2009 1:57 PM
 

Jamieson wrote
 

Interesting, I hadn't tried this.  But would this mean that the roles wouldn't synchronize with AD?  What would the ramifications of this be?

Role synchronization would go out the window. What other ramifications there would be I can't really say as I haven't used it a lot and it has been years.

 
New Post
4/6/2009 10:13 AM
 

nkayoumi wrote
 

I struggled with the same issue for way too many hours. In the end, the only way that I got it to work was to write my own code, which is below. It works perfectly now. If anyone knows of a better way to automatically login someone to the site without asking the user to click on a link to "windowsSignin.aspx" please let us know.

Paste this code in your global.asax.vb file and recompile your solution:

Private Sub Global_EndRequest(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.EndRequest
            Dim ps As DotNetNuke.Entities.Portals.PortalSettings = DirectCast(Context.Items("PortalSettings"), DotNetNuke.Entities.Portals.PortalSettings)
            If ps IsNot Nothing Then
                Dim tbinf As DotNetNuke.Entities.Tabs.TabInfo = ps.ActiveTab
                Dim mUser As DotNetNuke.Entities.Users.UserInfo = DotNetNuke.Entities.Users.UserController.GetCurrentUserInfo
                If mUser.UserID < 0 And _
                    InStr(Request.Url.OriginalString.ToLower, "ctl=logoff") < 1 And _
                    tbinf.TabName <> "Login" Then
                    Dim sCurrentPage As String = Mid(Request.PhysicalPath.ToLower, InStrRev(Request.PhysicalPath, "\") + 1)
                    If sCurrentPage <> "windowsSignin.aspx" Then                       
                        Response.Redirect("http://" & ps.PortalAlias.HTTPAlias & "/desktopmodules/authenticationservices/activedirectory/windowsSignin.aspx")
                    End If
                End If
            End If
        End Sub

I tried this script out of desperation, and it did seem to work, but people complained about performance.   I think the performance issue was unrelated and now fixed, but just curious, have you had any problems with this script working?  Also, if the original page requested was not the homepage, do the users get redirected after being logged in?

 
New Post
4/6/2009 10:39 AM
 

Interesting...  It appears that all that script modification does is to redirect the user to the WindowsSignIn.aspx file.

 
New Post
4/7/2009 1:08 PM
 

Dan, I tried your suggestion on my test server.  I downloaded DNN 5 again, and copied the release.config to my staging server.  I uninstalled active directory extension first, then replaced the web.config.  I then used "Beyond Compare" and copied over only the file differences that were essential, as you suggested.

I did notice that there were a lot of added entries, looks like most of it was added by Visual Studio 2008 (making it 3.5 compatible). 

To start testing, I setup AD the same as live, and then I logged out.  Immediately I saw a change.  On the live server, when I log out, I'm taken to the homepage.  On the test server though, I'm taken to the login page after logging out.

Another note, I'm not sure what the intended behavior is.  If I log out, and restart the browser, shouldn't I be automatically logged in?  Why is it that on the live server I see the homepage, and the test server the login page, but neither of them log me in automatically after logging out?  Is this by design?

Also, if you can explain if the discrepency means that the fixed on my test server worked, or if it's irrelevant, I'd appreciate the counsel.

 
Previous
 
Next
HomeHomeDNN Open Source...DNN Open Source...Provider and Extension ForumsProvider and Extension ForumsAuthenticationAuthenticationnot automatic login, but okay going to windowssigninnot automatic login, but okay going to windowssignin


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