New Posts New Posts RSS Feed: RegistryPermission request
  FAQ FAQ  Forum Search   Calendar   Register Register  Login Login

RegistryPermission request

 Post Reply Post Reply
Author
davidklitzke View Drop Down
IdeaBlade
IdeaBlade
Avatar

Joined: 14-Jun-2007
Posts: 715
Post Options Post Options   Quote davidklitzke Quote  Post ReplyReply Direct Link To This Post Topic: RegistryPermission request
    Posted: 10-Mar-2008 at 11:16am
This is a limitation of AspDataSource on DevForce 3.x.  It must run in a Full Trust environment.  It is not just RegistryPernission either.  It needs the ability to do Reflection as well.  The changes needed to change this would be enormous, so don't expect this behavior to change in DevForce 3.x.
 
The good news is that we will have a solution to this problem in some future version of DevForce EF, probably one that incorporates SilverLight technology
Back to Top
davidmgarrett View Drop Down
Newbie
Newbie


Joined: 09-Mar-2008
Posts: 1
Post Options Post Options   Quote davidmgarrett Quote  Post ReplyReply Direct Link To This Post Posted: 09-Mar-2008 at 9:13pm
I'm using DevForce Expres version 3.6.0.2, and I'm having similar problems running in a hosted environment,
although my failure occurs during initialization:
 
[SecurityException: Request for the permission of type 'System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' failed.]
   IdeaBlade.Util.IdeaBladeConfig.Initialize() +0
   IdeaBlade.Util.IdeaBladeConfig.get_Instance() +48
   IdeaBlade.Persistence.DataSourceResolver.GetProbedResolver() +19
   IdeaBlade.Persistence.DataSourceResolver..ctor(String pDataSourceExtensionName) +66
   IdeaBlade.Persistence.PersistenceManager..ctor(Boolean pShouldConnect, String pDataSourceExtension, PersistenceServiceOption pPersistenceServiceOption) +201

This seems like quite a shortcoming- are there plans to remedy it soon- perhaps in DevForce EF?
I have developed an extensive website only to find that I will have to completely rewrite the DAL if I can't deploy DevForce.  Hosting sites are certainly not going to grant read/write privs to the system registry on a shared server.
 
Are there any work-arounds you can suggest?
 
By the way, I love the simplicity of DevForce, and I caught the Microsoft Webinar on DevForce EF in February.
I look forward to your response.
 
Thanks in advance!
 
Back to Top
davidklitzke View Drop Down
IdeaBlade
IdeaBlade
Avatar

Joined: 14-Jun-2007
Posts: 715
Post Options Post Options   Quote davidklitzke Quote  Post ReplyReply Direct Link To This Post Posted: 29-Oct-2007 at 8:16am
The Persistence Manager must be given full trust.  Among other things, it needs full trust to read from and write to the registry.
Back to Top
greenman View Drop Down
Newbie
Newbie
Avatar

Joined: 05-Sep-2007
Location: Italy
Posts: 3
Post Options Post Options   Quote greenman Quote  Post ReplyReply Direct Link To This Post Posted: 26-Oct-2007 at 4:56pm
I've deployed an asp.net site with devforce 3.5.2.3 express. In my development workstation, all is working well, when I deploy the site in the hosting machine this exception bangs:
 
[SecurityException: Request for the permission of type 'System.Security.Permissions.RegistryPermission, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' failed.]
   System.Security.CodeAccessSecurityEngine.Check(Object demand, StackCrawlMark& stackMark, Boolean isPermSet) +0
   System.Security.CodeAccessPermission.Demand() +59
   Microsoft.Win32.RegistryKey.CheckSubKeyReadPermission(String subkeyName) +90
   Microsoft.Win32.RegistryKey.CheckOpenSubKeyPermission(String subkeyName, Boolean subKeyWritable) +25
   Microsoft.Win32.RegistryKey.OpenSubKey(String name, Boolean writable) +69
   IdeaBlade.Util.AuthHelper.GetRegKey(Boolean pWritable) +29
   IdeaBlade.Util.AuthHelper.InitializeFromRegistry() +12
   IdeaBlade.Util.AuthHelper.get_Instance() +131
   IdeaBlade.Util.IdeaBladeConfig.LoadLicenseInfo(Assembly pAssembly) +36
   IdeaBlade.Util.IdeaBladeConfig.Initialize() +212
   IdeaBlade.Util.IdeaBladeConfig.get_Instance() +48
   IdeaBlade.Persistence.DataSourceResolver.GetProbedResolver() +19
   IdeaBlade.Persistence.DataSourceResolver..ctor(String pDataSourceExtensionName) +63
   IdeaBlade.Persistence.PersistenceManager..ctor(Boolean pShouldConnect, String pDataSourceExtension, PersistenceServiceOption pPersistenceServiceOption) +201
 
It seems that devForce try to get the licence key or something else in the registry and causes the error. I have absolutely no control over the hosting machine. Thank you for your help.
Back to Top
 Post Reply Post Reply

Forum Jump Forum Permissions View Drop Down