[jbossseam-issues] [JBoss JIRA] Created: (JBSEAM-3389) seam-gen generated Authenticator component is not up to date

Joshua Partogi (JIRA) jira-events at lists.jboss.org
Sat Sep 6 13:17:38 EDT 2008


seam-gen generated Authenticator component is not up to date
------------------------------------------------------------

                 Key: JBSEAM-3389
                 URL: https://jira.jboss.org/jira/browse/JBSEAM-3389
             Project: Seam
          Issue Type: Task
          Components: Tools
    Affects Versions: 2.1.0.BETA1
         Environment: JBoss 4.2.2.GA, Eclipse 3.4
            Reporter: Joshua Partogi
            Priority: Minor


seam-gen is generating a Authenticator component code that is not up to date with the current API. It should be this:

@Name("authenticator")
public class Authenticator
{
    @Logger Log log;

    @In Identity identity;
    @In Credentials credentials;

    public boolean authenticate()
    {
        log.info("authenticating #0", credentials.getUsername());
        //write your authentication logic here,
        //return true if the authentication was
        //successful, false otherwise
        identity.addRole("admin");
        return true;
    }
}

And also on the login.xhtml:
                  <h:outputLabel for="username">Username</h:outputLabel>
                    <h:inputText id="username"
                              value="#{credentials.username}"/>
                    <h:outputLabel for="password">Password</h:outputLabel>
                    <h:inputSecret id="password"
                                value="#{credentials.password}"/> 

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        



More information about the seam-issues mailing list