Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Vincent Baaij 95 posts 344 karma points c-trib
    Feb 04, 2016 @ 09:31
    Vincent Baaij
    0

    How to: configure automatic member logon with windows authentication

    Here are the steps I followed to let members automatically login with Windows authentication:

    1) Install Active Directory Providers package (see project)

    2) Add connectionString in web.config:

    <add name="AdMembershipConnectionString" connectionString="LDAP://serveraddres" />
    

    3) Add membership provider in web.config

    <add name="ADMembersMembershipProvider" type="RB.ActiveDirectoryProviders.ActiveDirectoryUmbracoMembersMembershipProvider, RB.ActiveDirectoryProviders" connectionStringName="ADMembershipConnectionString" connectionUsername="{user with read acces to AD}" connectionPassword="{password}" attributeMapUsername="sAMAccountName" defaultMemberType="{groupname}" />
    

    4) Make the added provider the default provider

    <membership defaultProvider="ADMembersMembershipProvider" userIsOnlineTimeWindow="15">
    

    5) Set authentication in web.config to "Windows" (probably "Forms" now)

    6) Configure IIS to use Windows Authentication for the site

    7) If using IE set 'Enable Integrated Windows Authentication' to on (In advanced settings)

    That's it.

  • cchehn 28 posts 69 karma points
    Mar 04, 2016 @ 18:47
    cchehn
    0

    On a fresh install of 7.4.1 I installed the RB package via Package Manager Console in VS2013

    I made the updates suggested but now get a YSOD

    "Could not load file or assembly 'RB.ActiveDirectoryProviders' or one of its dependencies"

    I've tried Update-Package -reinstalled a few times, Rebuild a few times, Uninstall-Package then reinstall.

    But the error still persists. Any ideas?

    I'm going to try the Umbraco Package next, have to undo everything first.

  • Ben Sapp 2 posts 72 karma points
    Aug 16, 2017 @ 15:57
    Ben Sapp
    0

    Your assembly not loading is most likely because your Umbraco project targets .net 4.5, but the package targets 4.5.1.

    We worked through that issue but encountered a new problem, and gave up on this configuration.

    Today will try again:

    https://our.umbraco.org/documentation/Reference/Security/#authenticating-with-active-directory-credentials

  • 3ijtKwijt 36 posts 215 karma points
    Aug 17, 2017 @ 06:05
    3ijtKwijt
    0

    I tried the same. Added a role provider, but everytime I want to go to a restricted page, it links me to the error page instead of showing me the page (am logged in as a user who should have access to the page)

    Maybe I need a different login page than the one I am currently using, as for Public Access you need to specify both error page as login page, and what I currently did for login page is creating a login macro from the snippet and added that in the rich text field?

    Edit I did some more look up and I seem to be logged in, yet I keep getting the "Error page" instead of the page itself:

    CurrentUserName: domain\username 
    CurrentMember: 
    CurrentMemberId: -1 
    Is logged in: True; 
    Is member authorized: True 
    Page name: No Permissions
    

    Edit I think this ^ is because checking for roles uses the name without domain while checking with the Public Access gives domain\username ?

    Edit It was as I thought, so I editted the package that I was using to use the same name for checking the roles :)

Please Sign in or register to post replies

Write your reply to:

Draft