@RequiresPermissions(value = { "window:open", "door:close" }, logical
= Logical.OR)Kalle On Mon, Jul 30, 2012 at 2:25 PM, Felipe Carvalho <[email protected]> wrote: > BTW, I found out https://issues.apache.org/jira/browse/SHIRO-175 relates > exactly to what I need, but I can't find the > @RequiresAnyPermissions(String[] ) anywhere on the 1.1 or 1.2 distribution, > though. > > Does anyone know where can I find this annotation? > > Thanks! > > On Mon, Jul 30, 2012 at 6:12 PM, Felipe Carvalho <[email protected]> > wrote: >> >> Hello, >> I've been using @RequiresPermissions to check a single permission at a >> time, e.g.: @RequiresPermissions({"window:open"}). >> The problem is I need is to allow the same method to be executed by >> people with distinct permissions, e.g.: @RequiresPermissions({"window:open", >> "door:close"}). >> By reading the docs and looking at source code, I understood the list of >> strings passed as a parameter to @RequiresPermissions builds up an "AND" >> logical expression. Is there a way to build a "OR" logical expression? Is >> there some kind of @RequiresAnyPermissions ? >> >> Thanks! > >
