我正在尝试在 SharePoint 2007 (WSS 3.0) 中使用 LDAP 设置表单身份验证。我已成功看到users
前缀ad:<username>
,但无法让 roleManager 和adgroup:
前缀正常工作。很可能是提供程序类型错误。有人能建议正确的方法吗?
<connectionStrings>
<add name="ADConnectionString" connectionString="LDAP://domain:389/DC=domain,DC=local" />
</connectionStrings>
<!--******-->
<system.web>
<!--AD FBA-->
<membership defaultProvider="AD">
<providers>
<clear />
<add name="AD" type="System.Web.Security.ActiveDirectoryMembershipProvider, System.Web, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" connectionStringName="ADConnectionString" connectionUsername="domain\testgp" connectionPassword="SomePass" attributeMapUsername="SAMAccountName" enableSearchMethods="true" />
</providers>
</membership>
<roleManager defaultProvider="ADGroup">
<providers>
<clear />
<add name="ADGroup" type="System.Web.Security.ActiveDirectoryMembershipProvider, System.Web, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" connectionStringName="ADConnectionString" connectionUsername="domain\testgp" connectionPassword="SomePass" attributeMapUsername="SAMAccountName" enableSearchMethods="true" />
</providers>
</roleManager>