Running vb.net app (1.1) from a network share.


S

Shawn

I have a .net 1.1 app that runs from a network share. I signed it and can
add a machine policy to my computers and it runs fine, but I really need to
use a user policy to allow the app to run. I set the user policy the same as
the machine policy, but it fails to allow the app to run in Full Trust. Do I
need to sign the exe in a certain way? I can't find an answer out there.

Here is my AssemblyInfo.vb file...
Imports System.Reflection
Imports System.Runtime.InteropServices
<Assembly: AssemblyTitle("")>
<Assembly: AssemblyDescription("")>
<Assembly: AssemblyCompany("")>
<Assembly: AssemblyProduct("")>
<Assembly: AssemblyCopyright("")>
<Assembly: AssemblyTrademark("")>
<Assembly: CLSCompliant(True)>
<Assembly: AssemblyKeyFile("\\thci.com\NETLOGON\LogonApp.snk")>
<Assembly: Guid("7BF9B5D5-0EA0-4798-A979-7F3CE83E9FC0")>
<Assembly: AssemblyVersion("1.0.*")>

And my command to add the policy...

%windir%\microsoft.net\framework\v1.1.4322\caspol.exe -u -q -addgroup
All_Code -url "\\thci.com\NETLOGON\LogonApp.exe"

THANKS!!!!
 
Ad

Advertisements

R

Rory Becker

Hello Shawn,
I have a .net 1.1 app that runs from a network share. I signed it and
can add a machine policy to my computers and it runs fine, but I
really need to use a user policy to allow the app to run. I set the
user policy the same as the machine policy, but it fails to allow the
app to run in Full Trust. Do I need to sign the exe in a certain way?
I can't find an answer out there.

I'm afraid I don't have an answer that meets your criteria, but I thought
I'd just chip in that I've just heard that the latest 3.5 SP1 removes the
issues surrounding running managed code applications from a UNC Share.

This might do you some good int he future. Who knows?

Good luck finding you answer either way.
 
S

Shawn

Yeah, I heard that too but sadly, we have lots of computers only running
..net 1.1, so I needed to (painfully) re-install VS 2003 for this... Painful.
 
P

Phill W.

Shawn said:
I have a .net 1.1 app that runs from a network share. I signed it and can
add a machine policy to my computers and it runs fine, but I really need to
use a user policy to allow the app to run.

Why??

If it "runs fine" with /machine/ policies in place, why do you "need" to
use /user/ policies instead?
Here is my AssemblyInfo.vb file... .. . .
<Assembly: AssemblyKeyFile("\\thci.com\NETLOGON\LogonApp.snk")>
And my command to add the policy...

%windir%\microsoft.net\framework\v1.1.4322\caspol.exe -u -q -addgroup
All_Code -url "\\thci.com\NETLOGON\LogonApp.exe"

So now you're mentioning two files on the file share (the .exe and the
..snk) although that shouldn't matter because the KeyFile is used at
build-time but you're only "trusting" one of them (the .exe).

Try widening your CASPOL to allow anything in (or below) the program
directory:

....\caspol.exe ... -url "file://///thci.com/NETLOGON/*"

HTH,
Phill W.
 
S

Shawn

Users don't have local admin rights to their computers and our AD admins
don't want to push the msi to create the machine level permission.
 
Ad

Advertisements

P

Phill W.

Shawn said:
Users don't have local admin rights to their computers

Good ...
and our AD admins don't want to push the msi to create the machine
level permission.

Not so good ...

I've never used AD distribution but they /must/ have something that can
get "things" happening on the client machines, if only for regular
updates and the likes. Hopefully.

If they have, then you can get them to run the caspol command directly
(which how /my/ lot are doing this) just so long as you can get the
command itself working, of course ;-)

HTH,
Phill W.
 
Ad

Advertisements


Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top