MVC: creating a custom [AuthorizeAttribute] which takes parameters?
Here is my problem: I'm authorizing users on their roles, for 1 part. [Authorize(Roles = "Admin,...")] public class ModulesController : Controller { ..... } the Modules controller shows a list of modules which the user has right to. (there are a LOT of modules, but the user is only connected to a part of them). there are a load of things coupled to the modules, like questions, ... for example: the details view of the Modules controller. public ActionResult Details(int id) { var mod = (from p in _db.Modules where p.Mod_ID == id select p).First(); return accessible(mod); } [NonAction] public