Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie
Hi there,
There is an issue with role permissions that is being worked on at the moment.
If you are having trouble with access or permissions on regional forums please post here to get access: https://www.boards.ie/discussion/2058365403/you-do-not-have-permission-for-that#latest

Http authorisation username/password login

  • 08-05-2011 1:16pm
    #1
    Closed Accounts Posts: 16


    Hey,
    <input type="hidden" name="logintype" value="banner" />
    <div id='playerBox'>
            <div style="margin-left:5px;">
                    <div style="padding-bottom:7px"><h2>Registered users</h2></div>
                    <div style="margin:0px 0px 7px 0px">Existing players, log in here.</div>
                    <!-- login form starts -->                
                    <table cellpadding="0" cellspacing="0">
                            <tr>
                                    <td class="formTagCell">Email</td>
                                    <td class="formInputCell"><input type="text" name="email" id="email" maxlength="50" style="width:170px;padding:3px" /></td>
                            </tr>
                            <tr>
                                    <td class="formTagCell">Password</td>
                                    <td class="formInputCell"><input type="password" name="password" id="password" maxlength="50" style="width:170px;padding:3px" /></td>
                            </tr>
                            <tr>
                                    <td class="formTagCell">&nbsp;</td>
                                    <td class="formInputCell"><div class="smallText"><a href="forgotten.asp">Forgotten email or password? <br />Changed email? Click here &raquo;</a></div></td>
                            </tr>
                            <tr>
                                    <td class="formTagCell">&nbsp;</td>
                                    <td class="formInputCell" style="padding-top:5px;"><input type="image" src="_root/home/images/buttons/login.gif"></td>
                            </tr>
                    </table>
            </div>
            </form> 
            <!-- login form ends -->
    </div>
    

    This is a snippet of what is returning when I send a Http request from a small Java application, but I want to be able to see the actually html page visible when the user is logged in... Any ideas how I would go about authenticating the connection with my username/password pair?

    Any and all advice welcome!
    Thanks


Comments

  • Registered Users, Registered Users 2 Posts: 2,236 ✭✭✭techguy


    Have you tried something like Firebug to inspect what exactly is going on?

    You need to find out the URL that the form is posting to and all the data it's sending.

    Then reconstruct that within Java. You might also want to look into using cookies in Java.


  • Closed Accounts Posts: 16 FireHydrant


    Sweet, thanks!

    Any guidance is better than no guidance...


  • Registered Users, Registered Users 2 Posts: 183 ✭✭selfdiy


    I think the apache project commons-http if your not using it already will have some convenience methods that would be useful for this. I think they may also have some examples of programmatically logging in through java.


  • Registered Users, Registered Users 2 Posts: 757 ✭✭✭Signpost


    download fiddler and you can inspect all the traffic which should give you an easier idea of what is actually happening under the covers


Advertisement