项目作者: nicogis

项目描述 :
Store ArcGIS Server users and roles in a SQL Server security store and use also users Active Directory
高级语言: C#
项目地址: git://github.com/nicogis/AGSMixMembershipProvider.git
创建时间: 2016-09-19T17:50:02Z
项目社区:https://github.com/nicogis/AGSMixMembershipProvider

开源协议:

下载


ArcGIS Server Mix Provider

Mix Provider for ArcGIS Server

Requirements

ArcGIS Server 10.4 or superior

Description

Store ArcGIS Server users and roles in a SQL Server security store and use also users Active Directory

Installation

  • Install the mix provider .dll into the GAC.

gacutil /i AGSMixMembershipProvider.dll

  • Create a db in SQL Server/Express and run AGSMixMembershipProvider.sql in folder Support. Change in first row the name of your db

  • Open the ArcGIS Server Administrator Directory and log in with a user who has administrative permissions to your site.
    The Administrator Directory is typically available at http://gisserver.domain.com:6080/arcgis/admin.
    Click security > config > updateIdentityStore.
    Copy and paste the following text into the User Store Configuration dialog box on the Operation - updateIdentityStore page.

  1. {
  2. "type": "ASP_NET",
  3. "class": "AGSMixMembershipProvider.AGSMixMembershipProvider,AGSMixMembershipProvider,Version=1.0.0.0,Culture=Neutral,PublicKeyToken=4005576dfac9a17f",
  4. "properties": {
  5. "connectionStringName": "Data Source=.\\SQLEXPRESS;Initial Catalog=YourDB;User Id=UserDB;Password=PwdDB;",
  6. "passwordAD": "myPwdUserDomain",
  7. "usernameAD": "mydomain\\myUsernameUserDomain"
  8. }
  9. }

Update the user, password, name database and datasource values in property connectionStringName. Update user, domain and password for user that has privileges for browser AD.
Copy and paste the following text into the Role Store Configuration dialog box on the Operation - updateIdentityStore page.

  1. {
  2. "type": "ASP_NET",
  3. "class": "AGSMixMembershipProvider.AGSMixRoleProvider,AGSMixMembershipProvider,Version=1.0.0.0,Culture=Neutral,PublicKeyToken=4005576dfac9a17f",
  4. "properties": {
  5. "connectionStringName": "Data Source=.\\SQLEXPRESS;Initial Catalog=YourDB;User Id=UserDB;Password=PwdDB;",
  6. "passwordAD": "myPwdUserDomain",
  7. "usernameAD": "mydomain\\myUsernameUserDomain",
  8. "useRolesDBforAD": "true"
  9. }
  10. }

Update the user, password, name database and datasource values in property connectionStringName. Update user, domain and password for user that has privileges for browser AD.
Property useRolesDBforAD is true if you need also store Roles in sql server for users AD besides Roles in AD

  • Click Update to save your configuration.

  • Install two web adaptor in IIS and set Web-tier authentication. In the first enable only WA and in the second only Basic Authentication

  • For basic authentication (use only https!) you need create windows local users and add users in db sql server (username: ‘namemachine\nameuser’)

  • Add Role Provider in web.config of web adaptor in basic Authentication. If you need create also roles in sql server for user AD add it also in web.config of web adaptor WA ( useRolesDBforAD: true)

  1. <roleManager enabled="true" defaultProvider="AGSMixMembershipProvider">
  2. <providers>
  3. <clear ></clear>
  4. <!-- start this block-->
  5. <add name="AGSMixMembershipProvider" type="AGSMixMembershipProvider.AGSMixRoleProvider,AGSMixMembershipProvider,Version=1.0.0.0,Culture=Neutral,PublicKeyToken=4005576dfac9a17f"
  6. connectionStringName="Data Source=.\SQLEXPRESS;Initial Catalog=AGSMixMembershipProvider;User Id=UserDB;Password=PwdDB"
  7. passwordAD="myPwdUserDomain" usernameAD="mydomain\myUsernameUserDomain" useRolesDBforAD="true" ></add>
  8. <!-- end this block-->
  9. <add name="AspNetWindowsTokenRoleProvider" applicationName="arcgis" type="System.Web.Security.WindowsTokenRoleProvider, System.Web, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" ></add>
  10. </providers>
  11. </roleManager>