Test if current running assembly will trust a Security Zone

  • Thread starter Thread starter Clinton Pierce
  • Start date Start date
C

Clinton Pierce

I need to be able to test at runtime whether or not a component is going to
load properly from the Intranet.

Is there a way to query, "Will the current running assembly trust a
component loaded from the Intranet?"
 
Clinton Pierce said:
I need to be able to test at runtime whether or not a component is going to
load properly from the Intranet.

Is there a way to query, "Will the current running assembly trust a
component loaded from the Intranet?"

I'm not sure if this is what you want, but one thing you could do is to load
the assembly, obtain its evidence and then look at the permissions that CLR
grants to the assembly based on the evidence.

This is effectively what caspol -resolveperm does. You can see how caspol
does it by looking at its source code which comes with Rotor.

Regards,
Sami
 
Back
Top