在 sharepoint 中使用 FBA 激活自定义功能
我使用基于表单的身份验证为 sharepoint 中的站点创建了一个带有自定义功能接收器的功能。
但是,每当我尝试激活该功能(即使基于表单的帐户具有最高权限)时,我都会收到 403 -“需要您登录”。
我可以很好地激活和停用其他功能,但不是我的自定义功能。使用特征接收器创建特征是否有特殊技巧,可以让我做到这一点?
谢谢
I've created a feature with a custom feature receiver for a site in sharepoint, using forms based authentication.
However, whenever I try and activate the feature (even though the forms based account has top privileges) I get a 403 - "Requires you to be logged in".
I can activate and deactivate other features just fine, just not my custom one. Is there a special trick to creating features with a feature receiver allowing me to do this?
Thanks
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
显然,完全的管理员模拟和 RunWithElevatedPrivileges 成功了。
这是任何感兴趣的人的代码(位于 FeatureActivated/-Deactivated 方法中):
Apparently full admin-impersonation and RunWithElevatedPrivileges did the trick.
Here's the code for anyone interested (goes in the FeatureActivated/-Deactivated methods):