Index: org/apache/commons/httpclient/HttpMethodBase.java =================================================================== retrieving revision 1.159.2.18 diff -u -r1.159.2.18 HttpMethodBase.java --- org/apache/commons/httpclient/HttpMethodBase.java 3 Nov 2003 23:21:08 -0000 1.159.2.18 +++ org/apache/commons/httpclient/HttpMethodBase.java 22 Nov 2003 21:46:49 -0000 @@ -2377,10 +2377,15 @@ Header[] headers = getRequestHeaders(); for (int i = 0; i < headers.length; i++) { String s = headers[i].toExternalForm(); + if (headers[i].getName().equalsIgnoreCase("Authorization")) { + // write authorization header in UTF-8 + conn.write(HttpConstants.getContentBytes(s, "UTF-8")); + } else { + conn.print(s); + } if (Wire.enabled()) { Wire.output(s); } - conn.print(s); } } Index: org/apache/commons/httpclient/auth/DigestScheme.java =================================================================== retrieving revision 1.4.2.4 diff -u -r1.4.2.4 DigestScheme.java --- org/apache/commons/httpclient/auth/DigestScheme.java 4 Oct 2003 02:31:25 -0000 1.4.2.4 +++ org/apache/commons/httpclient/auth/DigestScheme.java 22 Nov 2003 21:46:50 -0000 @@ -276,7 +276,7 @@ LOG.warn("Unhandled algorithm " + algorithm + " requested"); a1 = uname + ":" + realm + ":" + pwd; } - String md5a1 = encode(md5Helper.digest(HttpConstants.getBytes(a1))); + String md5a1 = encode(md5Helper.digest(HttpConstants.getContentBytes(a1, "UTF-8"))); String serverDigestValue; String a2 = method + ":" + uri;