Loading Modules from a Network Share

Topics: CAB & Smart Client Software Factory
Oct 21, 2006 at 7:30 AM
originally posted by: glenmaroney


I believe with CAB I should be able to load modules which are stored on a network share? This works fine when I am running in debug in Visual Studio, however, when I try to load a network held module in the combined exe it just doesn't work.

I don't get any errors, the shell app just doesn't load.

I just have a simple shell app and a single module (TestModule.dll). My ProfileCatalog.xml only has one ModuleInfo node. If I point that to the C:\TestModule.dll it works fine, copy that dll to a network drive (Z:\) and modify the ModuleInfo to reference Z:\TestModule.dll and the shell app simply doesn't load.

Any ideas?
Oct 21, 2006 at 7:57 AM
originally posted by: kovlab49

Wouldn't the CLR consider that to be not a trusted location? It should throw something like an access violation I would think.
Oct 26, 2006 at 4:45 AM
originally posted by: rayn

I think kovlab49 is right.

Pull up the "Microsoft .NET Framework 2.0 Configuration" (Located in Control Panel/Administrative Tools)

Expand "My Computer" till you get to LocalIntranet_Zone on "Machine" (My Computer/Runtime Security Policy/Machine/Code Groups/)

Right-click LocalIntranetZone and select "Properties" from the context menu.

Under the "Permission Set" tab, change the Permission set to "FullTrust" and try running your application. It should now work.

Of course, this is not as secure so you'll want to go about a different way to implement this on another machine (e.g. set zone to trust you strongname signed app). However, it should at least get you up and running.