Turn-On & Turn-Off of CAS in .Net

Turn-On & Turn-Off of CAS in .net:
 
CAS
 
CAS is part of .net security model that prevents unauthorized access.
 
For turning on and off security you can use this tool:

Code Access Security Tool(Caspol.exe)
 
Procedure
 
Turn-On
 
 [To turn on security type following command in 'command prompt':]
 
 Caspol  -security on
 
Turn-Off
 
 [To turn off security type following command in 'command prompt':]
 
 Caspol  -security off

[In .net framework 4.0, for using 'caspol.exe' you first need to set the

<LegacyCasPolicy> to 'TRUE']