发布时出错:System.DirectoryServices.DirectoryServicesCOMException

2024-06-19

我在我的 asp.net MVC 解决方案中使用 AD 身份验证。它在本地服务器中工作,但是当我发布它时,我收到错误:“System.DirectoryServices.DirectoryServicesCOMException:发生操作错误。”。有人知道我必须做什么吗?


验证您是否要发布 dll:System.DirectoryServices.dll 和 System.DirectoryServices.AccountManagement.dll。

转到 Web 项目中的引用,找到两个引用,按 f4(属性选项卡),然后将“复制本地”设置为“True”。

-- 稍后添加

之后,在您的 iis 中验证“Asp.Net Impersonation”设置是否已启用。 (在 iis 中单击您的 Web 应用程序,然后在“授权”图标中单击)

本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)

发布时出错:System.DirectoryServices.DirectoryServicesCOMException 的相关文章

随机推荐