0

I am confused about what does the Unrestricted property of .Net security, as mentioned here, http://msdn.microsoft.com/en-us/library/system.security.permissions.securityattribute.unrestricted.aspx we could give it full or non-full.

My confusion is for permission in a straightforward understanding, there should be only two status -- granted and not-granted, what does th full and non-full mean? My confusion is the word "unrestricted" makes me think that when unrestricted is false, it means limited/partial permission (the opposite of full is partial/limited). Appreciate if anyone could clarify.

thanks in advance, George

George2
  • 44,761
  • 110
  • 317
  • 455

1 Answers1

1

George,

i think the key to understanding this property is the following line:

true if full permission to the protected resource is declared; otherwise, false.

As i see it, there is a resource and the Unrestricted property, which is a boolean, simply tells you if you have full permission or not.

Imagine that Unrestricted is actually renamed to FullPermission. i'm not sure why they didn't do that in the first place.

-p

Paul Sasik
  • 79,492
  • 20
  • 149
  • 189
  • If I set false to Unrestricted, it means no permission or partial permission? – George2 Jul 25 '09 at 05:33
  • 1
    That is how i understand it. Of course, the best thing to do is to code it and run it to make sure it behaves the way you/i expect. There are only two possibilities. ;-) – Paul Sasik Jul 25 '09 at 12:40
  • "is how i understand it" -- confused. Do you mean when unrestricted is assigned false, it means no permission or partial permission? – George2 Jul 25 '09 at 13:27