 |
|
In my recent SharePoint Advisor Article: Secure SharePoint Code Using Credential-less Impersonation, I describe a method of using the App Pool identity to complete tasks that the authenticated user doesn't have permission to do. Although I'm not a security expert, I wanted to share this approach that I find very beneficial. The RevertToAppPool class that I provide in the article requires an operating system routine which in turn requires the code to have Full trust (still better than storing credentials IMHO). However, I've recently become aware of an approach that achieves the same kind of impersonation under the preferred WSS_Medium trust level instead of Full.
Use the following RevertToAppPool class in place of the one that I provide in the article to achieve this goal: |
|
|
Thanks to Jeff Goddard in London, England for bringing this awesome option to my attention. As always, it is important to realize that any privilege that you give to the App Pool account could theoretically be exploited by someone with ill intensions. For most SharePoint implementations, this kind of class will be God-sent.
<Todd />