ASP.NET 3.5 + System.Web.Routing

时间:2010-08-12 00:00:55

标签: asp.net asp.net-3.5 url-routing asp.net-routing

我已经从hereDemo)下载了示例,但是当我在 Godady 服务器上部署它时,它给了我错误

Description: The application attempted to perform an operation not allowed by the security policy.  To grant this application the required permission please contact your system administrator or change the application's trust level in the configuration file. 

Exception Details: System.Security.SecurityException: Request for the permission of type 'System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' failed.

任何人都可以告诉我 Godady 有什么问题。此示例在本地计算机上正常工作。

1 个答案:

答案 0 :(得分:0)

我写信给戈达迪,但现在很困惑要问他们......

支持员工回应

  

感谢您在线联系   支持。

     

这看起来像一个信任问题。信任   level指的是在中设置的权限   Web.config文件决定了什么   操作可以也可以不执行   通过Web应用程序。我们的ASP.NET 3.5   共享主机服务器使用默认值   中等信任级别添加   OleDbPermission,OdbcPermission,   以及限制较少的WebPermission。   在Medium下运行的应用程序   信任级别没有注册表访问权限,   无法访问Windows事件日志,   并且不能使用ReflectionPermission   (但可以使用反射)。这样   应用程序只能与之通信   定义的网络地址范围   和文件系统访问仅限于   应用程序的虚拟目录   层次结构。

     

使用中等信任级别可防止   访问共享的应用程序   系统资源并消除了   申请的潜力   干扰。添加OleDbPermission   和OdbcPermission允许应用程序   使用这些数据提供者访问   数据库。 WebPermission已修改   允许出站http和https   流量。

     

如果我们能提供帮助,请告诉我们   你以任何其他方式。

客户咨询

  

我上传了我的网站   (http://www.pinchofbliss.com/anything

     

但我收到错误:

     

=============================================== =======================

     

描述:尝试了应用程序   执行不允许的操作   安全政策。授予这个   申请所需的许可   请联系您的系统   管理员或更改   应用程序的信任级别   配置文件。

     

异常详细信息:   System.Security.SecurityException:   请求类型的许可   “System.Security.Permissions.SecurityPermission,   mscorlib,版本= 2.0.0.0,   培养=中性

     

=============================================== =========================

     

有关详细信息,请让我写更多内容   此示例应用程序正常工作   在我放置的本地机器上   应用程序源代码   示例应用程序可以下载   从这里   http://chriscavanagh.wordpress.com/2008/03/11/aspnet-routing-goodbye-url-rewriting/