i m using .NET mvc2 for my application. I want some custom authorization on my actions. I have googled a bit and there seems to be two options available.
My question here is that which technique is preferable with pros and cons of using each technique
edited: Moreover I can override onActionExecuting and onAuthorization in my base controller that gives me benefit of accessing controller variables directly.
While both options are OK, it is best to subclass AuthorizeAttribute for these reasons:
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With