I have a controller and action that's responsible for handling 403s due to the users not being in the correct roles. It has access to the original RequestContext
that caused the exception.
What I would like to be able to do is decorate my actions with a description of what they do, then allow the user to notify their manager, requesting access including the description in an email.
So, how can I work out what action would be called given a RequestContext
?
Obviously this is more complicated that getting controller and action names out of the RouteData
since there are often overloads of an action method etc.
Once I have the MethodInfo
then it's easy to get attributes etc.