-1

I have a User model, UserServices and through the login page I want to authenticate a registered user.
Can you help me to write the method to be used in Authentication Controller?

<fieldset><legend>Authentication</legend>
<form:form action="login.htm"  commandName="user">
    <table>
        <tr>
            <td>User Name:<FONT color="red"><form:errors
                path="userName" /></FONT></td>
        </tr>
        <tr>
            <td><form:input path="userName" /></td>
        </tr>
        <tr>
            <td>Password:<FONT color="red"><form:errors
                path="password" /></FONT></td>
        </tr>
        <tr>
            <td><form:password path="password" /></td>
        </tr>
        <tr>
            <td><input type="submit" value="Submit" /></td>
        </tr>
    </table>
</form:form>
</fieldset>
2
  • @Logan these two links helped me the direction I was looking for! Thank you! Aug 7, 2012 at 12:59
  • @user1577291 If the answers were useful don't hesitate to upvote them and to accept one.
    – kgautron
    Aug 8, 2012 at 0:03

2 Answers 2

1

If you already use spring, you can easily add spring security to handle user authentication and permissions.

0
1

Here you can find a sample tutorial how to add spring security to your application. http://blog.rajithdelantha.com/2012/07/spring-security-part-1-sample-login.html

0

Not the answer you're looking for? Browse other questions tagged or ask your own question.