Fluent Security - configuring parameterized controller actions

前端 未结 1 1779
爱一瞬间的悲伤
爱一瞬间的悲伤 2021-01-19 16:50

I have done quite a bit of research and have tested both the 1.4 and 2.0 versions of the FluentSecurity libraries and I don\'t seem to be able to use the configuration patte

1条回答
  •  情话喂你
    2021-01-19 16:58

    I was asking the same question. Currently, you can pass in default values for the parameters.

    configuration
        .For(x => x.Index(default(string)))
        .DenyAnonymousAccess();
    

    where HomeController is:

    public ActionResult Index(string id)
    {
        return View();
    }
    

    0 讨论(0)
提交回复
热议问题