GeekInterview.com
   Home |  Tech FAQ  |   Interview Questions |  Placement Papers |  Tech Articles |  Learn |  Freelance Projects |  Online Testing |  Geeks Talk |  Job Postings |  Knowledge Base | Site Search |  Add/Ask Question

  GeekInterview.com  >  Interview Questions  >  Microsoft  >  ASP.NET

 Print  |  
Question:  Declarative Security and Imperative Security

Answer: What do you mean by Declarative Security and Imperative Security? Explain with an example of usage where you would use them


October 10, 2008 10:41:44 #1
 notouch   Member Since: October 2008    Total Comments: 1 

RE: Declarative Security and Imperative Security
 
You can see the detail in MSDN library: http://msdn.microsoft.com/en-us/library/0xkh23z7.aspx and http://msdn.microsoft.com/en-us/library/kaacwy28.aspx

From what I understand, Declarative Security can be used on Request, Demand and Overrides, Imperative can only be used on Demand and Overrides, but not Request.

Also imperative is used for determine security restriction based on run-time results. i.e. only users above age 17 can access rated M games. Both birth date and game rating are only available by user input at run time, so you will use imperative instead of declarative.
     

 

Back To Question