Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > ASP .Net Security > Can't get a code group to work

Reply
Thread Tools

Can't get a code group to work

 
 
Chris Cummings
Guest
Posts: n/a
 
      11-03-2003
I'm trying to use .Net Code Access Security. I've tried to
create a code group at the user level (using strong name
membership). Every time I run the app that is a member of
the group, I get a SecurityException and never even get
into Main(). This fails even if I set the PermissionSet of
the group to Everything. The only time I can get the app
to run is if I set the PermissionSet to Full Trust. Is
there something I need to change in security.config or
some Windows security setting I need to change?
 
Reply With Quote
 
 
 
 
Chris Cummings
Guest
Posts: n/a
 
      11-03-2003
OK, I found the reason. I have the code group flagged as
exclusive (i.e. only use the permissions of this group at
the user level). But I don't see why I can't mark it as
exclusive. The documentation says that a security
exception is thrown if the assembly is a member of more
that one exclusive group which is not the case???
>-----Original Message-----
>I'm trying to use .Net Code Access Security. I've tried

to
>create a code group at the user level (using strong name
>membership). Every time I run the app that is a member of
>the group, I get a SecurityException and never even get
>into Main(). This fails even if I set the PermissionSet

of
>the group to Everything. The only time I can get the app
>to run is if I set the PermissionSet to Full Trust. Is
>there something I need to change in security.config or
>some Windows security setting I need to change?
>.
>

 
Reply With Quote
 
 
 
 
Chris Cummings
Guest
Posts: n/a
 
      11-03-2003
Actually turning of the exclusive attribute of the code
group basically gives the assembly Full Trust from the
AllCode group, so I'm back to square one.
>-----Original Message-----
>I'm trying to use .Net Code Access Security. I've tried

to
>create a code group at the user level (using strong name
>membership). Every time I run the app that is a member of
>the group, I get a SecurityException and never even get
>into Main(). This fails even if I set the PermissionSet

of
>the group to Everything. The only time I can get the app
>to run is if I set the PermissionSet to Full Trust. Is
>there something I need to change in security.config or
>some Windows security setting I need to change?
>.
>

 
Reply With Quote
 
Chris Cummings
Guest
Posts: n/a
 
      11-03-2003
OK, I found out why. The assembly needs to be marked as
[assembly:AllowPartiallyTrustedCallers]
>-----Original Message-----
>I'm trying to use .Net Code Access Security. I've tried

to
>create a code group at the user level (using strong name
>membership). Every time I run the app that is a member of
>the group, I get a SecurityException and never even get
>into Main(). This fails even if I set the PermissionSet

of
>the group to Everything. The only time I can get the app
>to run is if I set the PermissionSet to Full Trust. Is
>there something I need to change in security.config or
>some Windows security setting I need to change?
>.
>

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Cant get Select Count(*)... GROUP BY to work Thomas ASP General 7 04-17-2006 06:09 PM
Multiple isakmp policies (Group 1 and Group 2) rmcnutt Cisco 1 07-13-2004 09:33 PM
Re: Which group is the PC discussion group (like comp.sys.mac.----)? philo Computer Support 0 08-03-2003 11:41 AM
Re: Which group is the PC discussion group (like comp.sys.mac.----)? LooseLips Computer Support 0 08-03-2003 08:37 AM



Advertisments