集不允许部分受信任的呼叫者

编程入门 行业动态 更新时间:2024-10-26 08:21:37
本文介绍了集不允许部分受信任的呼叫者的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

我建立使用流利的NHibernate的,这工作只是正常的开发框的网站。不过,我上传到我的主机后,我在尝试运行它时,下面的。

I am building a site using fluent NHibernate, which works just fine on the dev box. However, after I uploaded it to my host I get the following when trying to run it.

System.TypeInitializationException:为NHibernate.Byte code.Castle.ProxyFactory'的类型初始值引发了异常---> System.Security.SecurityException:那集不允许部分受信任的调用方

"System.TypeInitializationException: The type initializer for 'NHibernate.ByteCode.Castle.ProxyFactory' threw an exception. ---> System.Security.SecurityException: That assembly does not allow partially trusted callers.

这是不是我需要的托管公司(CrystalTech)来解决?任何帮助非常AP preciated。

Is this something I will need to resolve with the hosting company (CrystalTech)? Any help much appreciated.

内部异常的其余部分:

在Castle.DynamicProxy.ModuleScope..ctor(布尔savePhysicalAssembly,字符串strongAssemblyName,字符串strongModulePath,字符串weakAssemblyName,字符串weakModulePath)在Castle.DynamicProxy.ModuleScope..ctor(布尔savePhysicalAssembly)在Castle.DynamicProxy.ProxyGenerator..ctor ()在NHibernate.Byte code.Castle.ProxyFactory..cctor()失败了行动:失败的组件的LinkDemand区域是:我的电脑

at Castle.DynamicProxy.ModuleScope..ctor(Boolean savePhysicalAssembly, String strongAssemblyName, String strongModulePath, String weakAssemblyName, String weakModulePath) at Castle.DynamicProxy.ModuleScope..ctor(Boolean savePhysicalAssembly) at Castle.DynamicProxy.ProxyGenerator..ctor() at NHibernate.ByteCode.Castle.ProxyFactory..cctor() The action that failed was: LinkDemand The Zone of the assembly that failed was: MyComputer

---内部异常堆栈跟踪的结尾---

--- End of inner exception stack trace ---

推荐答案

NHibernate的不开箱工作在的中等信任环境(其中大多数共享主机中运行的应用程序)。 延迟加载与NHibernate在中信任介绍了一些所采取的措施,设法得到它的工作。

nHibernate does not work out of the box on a medium-trust environment (which most shared hosts run your application under). Lazy Loading with nHibernate Under Medium Trust describes some of the steps taken to try to get it working.

更多推荐

集不允许部分受信任的呼叫者

本文发布于:2023-11-05 08:43:40,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1560392.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:呼叫者   不允许

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!