Home All Groups Group Topic Archive Search About

permission for socket access

Author
22 Jun 2006 4:09 AM
Rain
Hi, i only need to make the scoket access unrestricted and nothing else. How
do i do this in an xml which i will be using in adding a permission set using
caspol?

<PermissionSet class="System.Security.NamedPermissionSet" version="1">
<Permission class="System.Net.SocketPermissionAttribute, mscorlib,
Ver=2000.14.1812.10, SN=03689116d3a4ae33" version="1">
  <Unrestricted />
  </Permission>
</PermissionSet>

This is my sample code but it doesnt work, it tells me that
System.Net.SocketPermissionAttribute is not valid. PLease, i need help.
Anyhelkp would be appreciated. Thank you so much in advance.

Author
22 Jun 2006 4:53 AM
Dominick Baier [DevelopMentor]
You can construct a NamedPermissionSet and a SocketException in code - and
afterwards call ToXml() on the permission set to get the xml representation.

---------------------------------------
Dominick Baier - DevelopMentor
http://www.leastprivilege.com

Show quoteHide quote
> Hi, i only need to make the scoket access unrestricted and nothing
> else. How do i do this in an xml which i will be using in adding a
> permission set using caspol?
>
> <PermissionSet class="System.Security.NamedPermissionSet" version="1">
> <Permission class="System.Net.SocketPermissionAttribute, mscorlib,
> Ver=2000.14.1812.10, SN=03689116d3a4ae33" version="1">
> <Unrestricted />
> </Permission>
> </PermissionSet>
> This is my sample code but it doesnt work, it tells me that
> System.Net.SocketPermissionAttribute is not valid. PLease, i need
> help. Anyhelkp would be appreciated. Thank you so much in advance.
>
Author
22 Jun 2006 4:57 AM
Dominick Baier [DevelopMentor]
oops. SocketPermission (note to self: coffee first)

---------------------------------------
Dominick Baier - DevelopMentor
http://www.leastprivilege.com

Show quoteHide quote
> You can construct a NamedPermissionSet and a SocketException in code -
> and afterwards call ToXml() on the permission set to get the xml
> representation.
>
> ---------------------------------------
> Dominick Baier - DevelopMentor
> http://www.leastprivilege.com
>> Hi, i only need to make the scoket access unrestricted and nothing
>> else. How do i do this in an xml which i will be using in adding a
>> permission set using caspol?
>>
>> <PermissionSet class="System.Security.NamedPermissionSet"
>> version="1">
>> <Permission class="System.Net.SocketPermissionAttribute, mscorlib,
>> Ver=2000.14.1812.10, SN=03689116d3a4ae33" version="1">
>> <Unrestricted />
>> </Permission>
>> </PermissionSet>
>> This is my sample code but it doesnt work, it tells me that
>> System.Net.SocketPermissionAttribute is not valid. PLease, i need
>> help. Anyhelkp would be appreciated. Thank you so much in advance.