myfaces-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Gerhard Petracek (JIRA)" <...@myfaces.apache.org>
Subject [jira] Created: (EXTCDI-59) @Secured for secured actions and beans
Date Sun, 19 Sep 2010 13:26:32 GMT
@Secured for secured actions and beans
--------------------------------------

                 Key: EXTCDI-59
                 URL: https://issues.apache.org/jira/browse/EXTCDI-59
             Project: MyFaces CODI
          Issue Type: New Feature
          Components: Core, JEE-JSF12-Module, JEE-JSF20-Module
            Reporter: Gerhard Petracek


via an interceptor it should be possible to create custom AccessDecisionVoter impelmentation/s
which check/s the permission to the target method.

example 1:

@Named
@RequestScoped
public class SecuredPage1
{
    @Secured(LoginVoter.class)
    public String order()
    {
       //...
    }
}

register a default error page via the view-config approach:

@Page
public class Login implements DefaultErrorPage
{
}

... leads to /login.xhtml as error-page.

example 2 (class level usage and special error page for this bean):

@Named
@RequestScoped
@Secured(value = LoginVoter.class, errorPage=SpecialErrorPage.class)
public class SecuredPage2
{
    public String order()
    {
       //...
    }
}



-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message