I’m using RazorGenerator to precompile the view. It works gerat in Full trust level. However my app runs in Shared hosting and thus requires to run under Medium trust.
I get the following error message:
*
[SecurityException: Request for the permission of type
‘System.Security.Permissions.FileIOPermission, mscorlib,
Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089’
failed.] System.Security.CodeAccessSecurityEngine.Check(Object
demand, StackCrawlMark& stackMark, Boolean isPermSet) +0
System.Security.CodeAccessSecurityEngine.Check(CodeAccessPermission
cap, StackCrawlMark& stackMark) +31
System.Security.CodeAccessPermission.Demand() +46
System.Reflection.RuntimeAssembly.get_Location() +100
RazorGenerator.Mvc.PrecompiledMvcEngine..ctor(Assembly assembly) +83
RGMvcApp.App_Start.RazorGeneratorMvcStart.Start() +109
*
It happens when defining/adding the new precompiled mvc view engine at App_Start.
There must be a solution for this.
Thanks in advance.
They’ve fixed it right away. Download the latest version.