I have seen the logger files now. Thanks for the help..
I have enclosed my log for anyone to
help me to see what I am doing wrong..
thanks
Bashiro
Bashiro
--- On Tue 09/11, Oleg Kalnichevski < [EMAIL PROTECTED] > wrote:
From: Oleg Kalnichevski [mailto: [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Cc: [email protected]
Date: Tue, 11 Sep 2007 17:39:49 +0200
Subject: Re: DNS
On Tue, 2007-09-11 at 09:37 -0400, Bashiro wrote:> Hello folks,> > i am writing
this client that updates a dns server (whereby i need first to login and the
perform the get command).> Whn I use the basic authentication example it works
fine> with some sites.> > But when i use on other sites that also need
authentication first and then a second get command, i receive error message
from httpclient that ; the site needs authentication but cannot find any. Why ?
can anyone explain to me what is wrong ?>> Any help/comments is welcome>
Thanks> Bashiro> Bashiro,Turn on wire/context logging and examine the
loghttp://jakarta.apache.org/httpcomponents/httpclient-3.x/logging.htmlOleg>
_______________________________________________> No banners. No pop-ups. No
kidding.> Make My Way your home on the Web - http://www.myway.com> > > >
---------------------------------------------------------------------> To
unsubscribe, e-mail: [EMAIL PROTECTED]> For additional
commands, e-mail: [EMAIL PROTECTED]> >
---------------------------------------------------------------------To
unsubscribe, e-mail: [EMAIL PROTECTED] additional commands, e-mail: [EMAIL
PROTECTED]
_______________________________________________
No banners. No pop-ups. No kidding.
Make My Way your home on the Web - http://www.myway.com
2007/09/11 20:40:55:515 BST [DEBUG] HttpClient - Java version: 1.6.0_02
2007/09/11 20:40:55:531 BST [DEBUG] HttpClient - Java vendor: Sun Microsystems
Inc.
2007/09/11 20:40:55:531 BST [DEBUG] HttpClient - Java class path:
E:\Dev\COMMONS_2007\commons-codec-1.3\commons-codec-1.3.jar;E:\Dev\COMMONS_2007\commons-httpclient-3.1\commons-httpclient-3.1.jar;E:\Dev\COMMONS_2007\commons-logging-1.1\commons-logging-1.1-ide.zip;E:\Dev\COMMONS_2007\commons-logging-1.1\commons-logging-1.1.jar;E:\Dev\COMMONS_2007\commons-logging-1.1\commons-logging-adapters-1.1.jar;E:\Dev\COMMONS_2007\commons-logging-1.1\commons-logging-api-1.1.jar;C:\Documents
and Settings\bashiro\HttpClient_2007\build\classes
2007/09/11 20:40:55:531 BST [DEBUG] HttpClient - Operating system name: Windows
XP
2007/09/11 20:40:55:531 BST [DEBUG] HttpClient - Operating system architecture:
x86
2007/09/11 20:40:55:531 BST [DEBUG] HttpClient - Operating system version: 5.1
2007/09/11 20:40:55:953 BST [DEBUG] HttpClient - SUN 1.6: SUN (DSA
key/parameter generation; DSA signing; SHA-1, MD5 digests; SecureRandom; X.509
certificates; JKS keystore; PKIX CertPathValidator; PKIX CertPathBuilder; LDAP,
Collection CertStores, JavaPolicy Policy; JavaLoginConfig Configuration)
2007/09/11 20:40:55:953 BST [DEBUG] HttpClient - SunRsaSign 1.5: Sun RSA
signature provider
2007/09/11 20:40:55:953 BST [DEBUG] HttpClient - SunJSSE 1.6: Sun JSSE
provider(PKCS12, SunX509 key/trust factories, SSLv3, TLSv1)
2007/09/11 20:40:55:953 BST [DEBUG] HttpClient - SunJCE 1.6: SunJCE Provider
(implements RSA, DES, Triple DES, AES, Blowfish, ARCFOUR, RC2, PBE,
Diffie-Hellman, HMAC)
2007/09/11 20:40:55:953 BST [DEBUG] HttpClient - SunJGSS 1.0: Sun (Kerberos v5,
SPNEGO)
2007/09/11 20:40:55:968 BST [DEBUG] HttpClient - SunSASL 1.5: Sun SASL
provider(implements client mechanisms for: DIGEST-MD5, GSSAPI, EXTERNAL, PLAIN,
CRAM-MD5; server mechanisms for: DIGEST-MD5, GSSAPI, CRAM-MD5)
2007/09/11 20:40:55:968 BST [DEBUG] HttpClient - XMLDSig 1.0: XMLDSig (DOM
XMLSignatureFactory; DOM KeyInfoFactory)
2007/09/11 20:40:55:968 BST [DEBUG] HttpClient - SunPCSC 1.6: Sun PC/SC provider
2007/09/11 20:40:55:968 BST [DEBUG] HttpClient - SunMSCAPI 1.6: Sun's Microsoft
Crypto API provider
2007/09/11 20:40:56:000 BST [DEBUG] DefaultHttpParams - Set parameter
http.useragent = Jakarta Commons-HttpClient/3.1
2007/09/11 20:40:56:000 BST [DEBUG] DefaultHttpParams - Set parameter
http.protocol.version = HTTP/1.1
2007/09/11 20:40:56:000 BST [DEBUG] DefaultHttpParams - Set parameter
http.connection-manager.class = class
org.apache.commons.httpclient.SimpleHttpConnectionManager
2007/09/11 20:40:56:000 BST [DEBUG] DefaultHttpParams - Set parameter
http.protocol.cookie-policy = default
2007/09/11 20:40:56:000 BST [DEBUG] DefaultHttpParams - Set parameter
http.protocol.element-charset = US-ASCII
2007/09/11 20:40:56:000 BST [DEBUG] DefaultHttpParams - Set parameter
http.protocol.content-charset = ISO-8859-1
2007/09/11 20:40:56:000 BST [DEBUG] DefaultHttpParams - Set parameter
http.method.retry-handler = [EMAIL PROTECTED]
2007/09/11 20:40:56:000 BST [DEBUG] DefaultHttpParams - Set parameter
http.dateparser.patterns = [EEE, dd MMM yyyy HH:mm:ss zzz, EEEE, dd-MMM-yy
HH:mm:ss zzz, EEE MMM d HH:mm:ss yyyy, EEE, dd-MMM-yyyy HH:mm:ss z, EEE,
dd-MMM-yyyy HH-mm-ss z, EEE, dd MMM yy HH:mm:ss z, EEE dd-MMM-yyyy HH:mm:ss z,
EEE dd MMM yyyy HH:mm:ss z, EEE dd-MMM-yyyy HH-mm-ss z, EEE dd-MMM-yy HH:mm:ss
z, EEE dd MMM yy HH:mm:ss z, EEE,dd-MMM-yy HH:mm:ss z, EEE,dd-MMM-yyyy HH:mm:ss
z, EEE, dd-MM-yyyy HH:mm:ss z]
2007/09/11 20:40:56:093 BST [DEBUG] HttpConnection - Open connection to
members.dyndns.org:80
2007/09/11 20:40:56:312 BST [DEBUG] header - >> "GET
/nic/update?hostname=test.dyndns.org&myip=ipaddress&wildcard=NOCHG&mx=NOCHG&backmx=NOCHG
HTTP/1.1[\r][\n]"
2007/09/11 20:40:56:312 BST [DEBUG] HttpMethodBase - Adding Host request header
2007/09/11 20:40:56:328 BST [DEBUG] header - >> "User-Agent: Jakarta
Commons-HttpClient/3.1[\r][\n]"
2007/09/11 20:40:56:328 BST [DEBUG] header - >> "Host:
members.dyndns.org[\r][\n]"
2007/09/11 20:40:56:328 BST [DEBUG] header - >> "[\r][\n]"
2007/09/11 20:40:56:500 BST [DEBUG] header - << "HTTP/1.1 401 Authorization
Required[\r][\n]"
2007/09/11 20:40:56:500 BST [DEBUG] header - << "HTTP/1.1 401 Authorization
Required[\r][\n]"
2007/09/11 20:40:56:500 BST [DEBUG] header - << "Date: Tue, 11 Sep 2007
18:40:31 GMT[\r][\n]"
2007/09/11 20:40:56:515 BST [DEBUG] header - << "Server: Apache[\r][\n]"
2007/09/11 20:40:56:515 BST [DEBUG] header - << "X-UpdateCode: A[\r][\n]"
2007/09/11 20:40:56:515 BST [DEBUG] header - << "WWW-Authenticate: Basic
realm="DynDNS API Access"[\r][\n]"
2007/09/11 20:40:56:515 BST [DEBUG] header - << "Content-Length: 7[\r][\n]"
2007/09/11 20:40:56:515 BST [DEBUG] header - << "Connection: close[\r][\n]"
2007/09/11 20:40:56:515 BST [DEBUG] header - << "Content-Type: text/html;
charset=iso-8859-1[\r][\n]"
2007/09/11 20:40:56:515 BST [DEBUG] header - << "[\r][\n]"
2007/09/11 20:40:56:515 BST [DEBUG] HttpMethodDirector - Authorization required
2007/09/11 20:40:56:531 BST [DEBUG] AuthChallengeProcessor - Supported
authentication schemes in the order of preference: [ntlm, digest, basic]
2007/09/11 20:40:56:531 BST [DEBUG] AuthChallengeProcessor - Challenge for ntlm
authentication scheme not available
2007/09/11 20:40:56:531 BST [DEBUG] AuthChallengeProcessor - Challenge for
digest authentication scheme not available
2007/09/11 20:40:56:531 BST [INFO] AuthChallengeProcessor - basic
authentication scheme selected
2007/09/11 20:40:56:531 BST [DEBUG] AuthChallengeProcessor - Using
authentication scheme: basic
2007/09/11 20:40:56:531 BST [DEBUG] AuthChallengeProcessor - Authorization
challenge processed
2007/09/11 20:40:56:531 BST [DEBUG] HttpMethodDirector - Authentication scope:
BASIC 'DynDNS API Access'@members.dyndns.org:80
2007/09/11 20:40:56:531 BST [DEBUG] HttpMethodDirector - Retry authentication
2007/09/11 20:40:56:531 BST [DEBUG] HttpMethodBase - Should close connection in
response to directive: close
2007/09/11 20:40:56:531 BST [DEBUG] HttpConnection - Connection is locked.
Call to releaseConnection() ignored.
2007/09/11 20:40:56:531 BST [DEBUG] HttpMethodDirector - Authenticating with
BASIC 'DynDNS API Access'@members.dyndns.org:80
2007/09/11 20:40:56:531 BST [DEBUG] HttpMethodParams - Credential charset not
configured, using HTTP element charset
2007/09/11 20:40:56:562 BST [DEBUG] HttpConnection - Open connection to
members.dyndns.org:80
2007/09/11 20:40:56:703 BST [DEBUG] header - >> "GET
/nic/update?hostname=test.dyndns.org&myip=ipaddress&wildcard=NOCHG&mx=NOCHG&backmx=NOCHG
HTTP/1.1[\r][\n]"
2007/09/11 20:40:56:703 BST [DEBUG] HttpMethodBase - Adding Host request header
2007/09/11 20:40:56:703 BST [DEBUG] header - >> "User-Agent: Jakarta
Commons-HttpClient/3.1[\r][\n]"
2007/09/11 20:40:56:703 BST [DEBUG] header - >> "Authorization: Basic
dGVzdDp0ZXN0[\r][\n]"
2007/09/11 20:40:56:703 BST [DEBUG] header - >> "Host:
members.dyndns.org[\r][\n]"
2007/09/11 20:40:56:703 BST [DEBUG] header - >> "[\r][\n]"
2007/09/11 20:40:56:859 BST [DEBUG] header - << "HTTP/1.1 200 OK[\r][\n]"
2007/09/11 20:40:56:859 BST [DEBUG] header - << "HTTP/1.1 200 OK[\r][\n]"
2007/09/11 20:40:56:859 BST [DEBUG] header - << "Date: Tue, 11 Sep 2007
18:40:32 GMT[\r][\n]"
2007/09/11 20:40:56:859 BST [DEBUG] header - << "Server: Apache[\r][\n]"
2007/09/11 20:40:56:859 BST [DEBUG] header - << "X-UpdateCode: N[\r][\n]"
2007/09/11 20:40:56:859 BST [DEBUG] header - << "Content-Type:
text/plain[\r][\n]"
2007/09/11 20:40:56:859 BST [DEBUG] header - << "Connection: close[\r][\n]"
2007/09/11 20:40:56:859 BST [DEBUG] header - << "Transfer-Encoding:
chunked[\r][\n]"
2007/09/11 20:40:56:859 BST [DEBUG] header - << "[\r][\n]"
2007/09/11 20:40:56:859 BST [WARN] HttpMethodBase - Going to buffer response
body of large or unknown size. Using getResponseBodyAsStream instead is
recommended.
2007/09/11 20:40:56:875 BST [DEBUG] HttpMethodBase - Buffering response body
2007/09/11 20:40:56:875 BST [DEBUG] header - << "[\r][\n]"
2007/09/11 20:40:56:875 BST [DEBUG] HttpMethodBase - Should close connection in
response to directive: close
2007/09/11 20:40:56:875 BST [DEBUG] HttpConnection - Releasing connection back
to connection manager.
2007/09/11 20:40:56:875 BST [DEBUG] HttpMethodBase - Default charset used:
ISO-8859-1
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]