Creating HTTP authentication on a Lotus Domino server

351965 pts.
Tags:
Authentication
Lotus Domino
Lotus Notes Database
I've been trying to an Android application that would be capable of reading different amounts of data from a Lotus Notes database. I've already started to create the a page to test the HTTP authentication and have run into some problems. Here's my code:
  public void GoAuth(View v){
    final String httpsURL = "http://xxx.xxx.xxx.xxx/names.nsf/mypage?openpage";
    final DefaultHttpClient client = new DefaultHttpClient();
    final HttpPost httppost = new HttpPost(httpsURL);

    String userName = "demo";
    String password = "demo";

    try {
        //authentication block:
        final List nvps = new ArrayList();
        nvps.add(new BasicNameValuePair("Username", userName));
        nvps.add(new BasicNameValuePair("Password", password));
        final UrlEncodedFormEntity p_entity = new UrlEncodedFormEntity(nvps, HTTP.UTF_8);
        httppost.setEntity(p_entity);

        //sending the request and retrieving the response:
        HttpResponse response = client.execute(httppost);
        HttpEntity responseEntity = response.getEntity();

        if (response.getStatusLine().getStatusCode() == HttpURLConnection.HTTP_OK){
            //handling the response 
            final InputSource inputSource = new InputSource(responseEntity.getContent());
            TextView res=(TextView)findViewById(R.id.result);
            res.setText("Server response: "+inputSource.toString());
        }

    } catch (UnsupportedEncodingException e) {
        // TODO Auto-generated catch block
        e.printStackTrace();
    } catch (ClientProtocolException e) {
        // TODO Auto-generated catch block
        e.printStackTrace();
    } catch (IllegalStateException e) {
        // TODO Auto-generated catch block
        e.printStackTrace();
    } catch (IOException e) {
        // TODO Auto-generated catch block
        e.printStackTrace();
    }


}
This is what I'm getting from the server: org.xml.sax InputSource@40575700. What's the right approach here?

Answer Wiki

Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Discuss This Question:  

 
There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to:

To follow this tag...

There was an error processing your information. Please try again later.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Thanks! We'll email you when relevant content is added and updated.

Following