jon
jon

Reputation: 980

Java Authentication Form - Etat HTTP 408 - The time allowed for the login process has been exceeded

we need to authenticate users when they access certain group of web services. For that we use auth-method FORM.

When user enters info inside text area and clicks the button, application will try to call a web service. This web service is secured and user needs to authenticate first. The auth form will be displayed as a popup (jquery effect).

Here is the code:

     <!DOCTYPE html>
    ...
    <meta http-equiv="Cache-Control" content="no-store,no-cache,must-revalidate"/>
    <meta http-equiv="Pragma" content="no-cache"/>
    <meta http-equiv="Expires" content="-1"/>
    ...
    <script src="//code.jquery.com/jquery-1.9.1.min.js"></script>
    <script src="jquery.bpopup.min.js"></script>
    <script type="text/javascript">

        $(document).ready(function() {
            var $form = $('form');

               ;(function($) {
                  $(function() {
                    $('#update').bind('click', function(e) {
                        e.preventDefault();
                        $('#popupLogin').bPopup();
                    });
                });
              })(jQuery);


           });
    </script>
    </head>

<body>
    <div style="padding-left: 30px;">
        <h1 style="padding-left: -20px;">Create a new <i>Clinic</i></h1>
    <div id="popupLogin" style="display:none;">
        <form action="j_security_check" method="post">
            <div>
                <table>
                    <tr>
                        <td><span>Username</span></td>
                        <td><input type="text" style="width: 50px;" name="j_username" /></td>
                    </tr>
                    <tr>
                        <td><span>Password</span></td>
                        <td><input type="password" style="width: 50px;" name="j_password" /></td>
                    </tr>
                    <tr>
                        <td colspan="2"><input type="submit" value="Login" /></td>
                    </tr>
                </table>
            </div>
        </form>
    </div>
    <form id="form">
        Clinic Name: <input type="text" name="name" /><br /><br />
        <input type="button" id="update" value="Add Clinic" />  
    </form>
</div>

The problem is that whenever i submit the right info for login, it redirects to this 408 error:

Etat HTTP 408 - The time allowed for the login process has been exceeded. If you wish to continue you must either click back twice and re-click the link you requested or close and re-open your browser

Any idea for a solution?

Upvotes: 3

Views: 507

Answers (0)

Related Questions