开发者

What's the easiest way to determine if a method call will run under Medium Trust?

开发者 https://www.devze.com 2022-12-21 13:57 出处:网络
Is there a quick way to determine if a method call will run under medium trust?In this scenario, I\'m specifically wanting to know about trust-level requirements for .NET Framework method开发者_运维技

Is there a quick way to determine if a method call will run under medium trust? In this scenario, I'm specifically wanting to know about trust-level requirements for .NET Framework method开发者_运维技巧s. Thanks!


Check MSDN or use Reflector to check attributes.

This is just an example of the type of attribute you will be looking for.

[AspNetHostingPermission(SecurityAction.LinkDemand, Level=AspNetHostingPermissionLevel.Minimal)]
public static class ProfileManager
{


You need to set trust level medium in your web.config file

0

精彩评论

暂无评论...
验证码 换一张
取 消