Code access security : codegroups

  • Thread starter Thread starter Chris
  • Start date Start date
C

Chris

Hi,

when an assembly is loaded by the runtime does the runtime check the
evidence of the assembly. Then depending on the evidence does it assign the
assembly to a codeGroup. And finally, depending on the permission sets
assigned to the Codegroup (the assembl belongs to) is it allowed (or not) to
execute specific tasks.

My question is ? how can I make my assembly belong to a specific code group
?

Here's what I did :

Using the tool mscorcfg.msc did I :
1) create a MyPermissionSet
2) assign a few permissions to the set such as FileIO and FileDialog

3) create a My_CodeGroup
4) assigned the MyPermissionSet to My_CodeGroup

Now, how can I have a MyApplication (assembly) belong to My_CodeGroup ?

Thnx

Christian
 
Now, how can I have a MyApplication (assembly) belong to My_CodeGroup ?

That's set up via the membership condition of the code group. Maybe the best
option for you would be Strong Name or Application Directory. This can be
edited in the admin tool for the code group.


HTH;
Eric Cadwell
http://www.origincontrols.com
 
Back
Top