Hi, All,

I'm writing an application to log into a website via a form.  I've tried
many different ways, but each time, I get re-directed to a page saying
I'm being "redirected to an authentication service on another device".
(I'm not able to get to this page via a browser.)

I downloaded a browser sniffer program, but when it's running, the
website I'm trying to log into won't load properly (via the browser).

So, is it possible for a company to disable programmatic access on the
server side?  Can they have something set up to block this type of
log-in?

Just in case it's helpful, here is the latest version of code I'm using.
Again, I've tried several versions.  I'd be happy to share the other
versions if that will be helpful.  I do have wire logging turned on and
would be happy to share those files also.

// BEGIN OF CODE

String response = "";

GetMethod authget = new GetMethod("https://www.somesite.com";);
(new HttpClient()).executeMethod(authget);
response = authget.getResponseBodyAsString();
System.out.println("Body from authget " + response);

PostMethod authPost = new PostMethod("https://www.somesite.com";);

NameValuePair[] paramList = {
        new NameValuePair("SMENC", "ISO-8859-1"),
        new NameValuePair("SMLOCAE", "US-EN"),
        new NameValuePair("TARGET", "/login/index.html"),
        new NameValuePair("USER", "username"),
        new NameValuePair("PASSWORD", "password"),
        new NameValuePair("lowBandwidth", "false")
};
                        
System.out.println("Response body is " + response);
System.out.println("Login form post (authPost): " +
authPost.getStatusLine().toString());

// END OF CODE

Thank you for your time and consideration,

 - Stephanie

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to