【问题标题】:ReflectionPermission not granted even though Trust level is High即使信任级别为高,也未授予 ReflectionPermission
【发布时间】:2012-08-08 19:07:17
【问题描述】:

我正在尝试在 Windows 2008、IIS 7.5 上运行 ASP.NET 2.0 应用程序。应用程序抛出此异常:

SecurityException: 请求类型的权限 'System.Security.Permissions.ReflectionPermission, mscorlib, 版本=2.0.0.0,文化=中性,PublicKeyToken=b77a5c561934e089' 失败。]

即使应用程序在trust level = "Full" 上运行,如web.config 中指定的那样。是的,框架 web.config 配置为允许覆盖信任级别。

我感觉盒子上的安全策略正在阻止应用程序在这种信任级别上实际运行,即使我们明确指示它这样做。该应用程序在 Win7 上的 dev 中运行良好。

感谢您的任何想法。

【问题讨论】:

    标签: asp.net security iis-7.5 code-access-security


    【解决方案1】:

    在“解锁”特定 dll 及其 pdb 和 xml 文件后,问题得到解决。 (右键,属性,点击“解除阻止”按钮。)

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 2019-03-20
      • 1970-01-01
      • 2023-03-12
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多