Hi Ben, can you compare the requests sent in both cases (only a part of the request from WebTest is available in the log you provided). If you only toggle the httpclient.wire to debug, you will just "see" the content on the wire, not the internal debug statements.
I've never seen such a problem. What do you use for a servlet container? Is the security directly handled by it? Marc. [EMAIL PROTECTED] wrote: > Hi Mark, > > Yes the realm="default" parameter is missing from the response when > accessing > through WebTest. Below is the output :- > > DEBUG (httpclient.wire.header) - >> "User-Agent: Mozilla/4.0 > (compatible; MSIE 6.0b; Windows 98)[\r][\n]" > DEBUG (org.apache.commons.httpclient.HttpConnection) - enter > HttpConnection.print(String) > DEBUG (org.apache.commons.httpclient.HttpConnection) - enter > HttpConnection.write(byte[]) > DEBUG (org.apache.commons.httpclient.HttpConnection) - enter > HttpConnection.write(byte[], int, int) > DEBUG (httpclient.wire.header) - >> "Host: localhost:7001[\r][\n]" > DEBUG (org.apache.commons.httpclient.HttpConnection) - enter > HttpConnection.print(String) > DEBUG (org.apache.commons.httpclient.HttpConnection) - enter > HttpConnection.write(byte[]) > DEBUG (org.apache.commons.httpclient.HttpConnection) - enter > HttpConnection.write(byte[], int, int) > DEBUG (org.apache.commons.httpclient.HttpConnection) - enter > HttpConnection.writeLine() > DEBUG (org.apache.commons.httpclient.HttpConnection) - enter > HttpConnection.write(byte[]) > DEBUG (org.apache.commons.httpclient.HttpConnection) - enter > HttpConnection.write(byte[], int, int) > DEBUG (httpclient.wire.header) - >> "[\r][\n]" > DEBUG (org.apache.commons.httpclient.HttpConnection) - enter > HttpConnection.flushRequestOutputStream() > DEBUG (org.apache.commons.httpclient.HttpMethodBase) - enter > HttpMethodBase.readResponse(HttpState, HttpConnection) > DEBUG (org.apache.commons.httpclient.HttpMethodBase) - enter > HttpMethodBase.readStatusLine(HttpState, HttpConnection) > DEBUG (org.apache.commons.httpclient.HttpConnection) - enter > HttpConnection.readLine() > DEBUG (org.apache.commons.httpclient.HttpParser) - enter > HttpParser.readLine(InputStream, String) > DEBUG (org.apache.commons.httpclient.HttpParser) - enter > HttpParser.readRawLine() > DEBUG (httpclient.wire.header) - << "HTTP/1.1 401 Unauthorized[\r][\n]" > DEBUG (org.apache.commons.httpclient.HttpMethodBase) - enter > HttpMethodBase.readResponseHeaders(HttpState,HttpConnection) > DEBUG (org.apache.commons.httpclient.HttpConnection) - enter > HttpConnection.getResponseInputStream() > DEBUG (org.apache.commons.httpclient.HttpParser) - enter > HeaderParser.parseHeaders(InputStream, String) > DEBUG (org.apache.commons.httpclient.HttpParser) - enter > HttpParser.readLine(InputStream, String) > DEBUG (org.apache.commons.httpclient.HttpParser) - enter > HttpParser.readRawLine() > DEBUG (org.apache.commons.httpclient.HttpParser) - enter > HttpParser.readLine(InputStream, String) > DEBUG (org.apache.commons.httpclient.HttpParser) - enter > HttpParser.readRawLine() > DEBUG (org.apache.commons.httpclient.HttpParser) - enter > HttpParser.readLine(InputStream, String) > DEBUG (org.apache.commons.httpclient.HttpParser) - enter > HttpParser.readRawLine() > DEBUG (org.apache.commons.httpclient.HttpParser) - enter > HttpParser.readLine(InputStream, String) > DEBUG (org.apache.commons.httpclient.HttpParser) - enter > HttpParser.readRawLine() > DEBUG (org.apache.commons.httpclient.HttpParser) - enter > HttpParser.readLine(InputStream, String) > DEBUG (org.apache.commons.httpclient.HttpParser) - enter > HttpParser.readRawLine() > DEBUG (org.apache.commons.httpclient.HttpParser) - enter > HttpParser.readLine(InputStream, String) > DEBUG (org.apache.commons.httpclient.HttpParser) - enter > HttpParser.readRawLine() > DEBUG (org.apache.commons.httpclient.HttpParser) - enter > HttpParser.readLine(InputStream, String) > DEBUG (org.apache.commons.httpclient.HttpParser) - enter > HttpParser.readRawLine() > DEBUG (org.apache.commons.httpclient.HttpParser) - enter > HttpParser.readLine(InputStream, String) > DEBUG (org.apache.commons.httpclient.HttpParser) - enter > HttpParser.readRawLine() > DEBUG (org.apache.commons.httpclient.HttpParser) - enter > HttpParser.readLine(InputStream, String) > DEBUG (org.apache.commons.httpclient.HttpParser) - enter > HttpParser.readRawLine() > DEBUG (org.apache.commons.httpclient.HttpParser) - enter > HttpParser.readLine(InputStream, String) > DEBUG (org.apache.commons.httpclient.HttpParser) - enter > HttpParser.readRawLine() > DEBUG (httpclient.wire.header) - << "Cache-Control: > no-cache="set-cookie"[\r][\n]" > DEBUG (httpclient.wire.header) - << "Connection: close[\r][\n]" > DEBUG (httpclient.wire.header) - << "Date: Thu, 09 Aug 2007 15:41:06 > GMT[\r][\n]" > DEBUG (httpclient.wire.header) - << "Content-Length: 1518[\r][\n]" > DEBUG (httpclient.wire.header) - << "Content-Type: text/html[\r][\n]" > DEBUG (httpclient.wire.header) - << "WWW-Authenticate: > Negotiate[\r][\n]" > DEBUG (httpclient.wire.header) - << "WWW-Authenticate: Basic[\r][\n]" > DEBUG (httpclient.wire.header) - << "Set-Cookie: > JSESSIONID=wCbhG71S8gvsVcYk6MFLHfqvkX5c20x9nLrLy6KkpvC2zQ2GH4yy!17766311 > 57; path=/[\r][\n]" > DEBUG (httpclient.wire.header) - << "X-Powered-By: Servlet/2.4 > JSP/2.0[\r][\n]" > DEBUG (org.apache.commons.httpclient.HttpMethodBase) - enter > HttpMethodBase.processResponseHeaders(HttpState, HttpConnection) > > Is this a problem you've encountered previously? Thanks, > > Ben > > > > Message: 3 > Date: Wed, 8 Aug 2007 15:11:51 +0100 > From: <[EMAIL PROTECTED]> > To: <[email protected]> > Subject: [Webtest] RE: Basic authentication ([EMAIL PROTECTED]) > Reply-To: [email protected] > Reply-To: <[EMAIL PROTECTED]> > > > > Hi Mark thanks for your response. > > Yes this was my initial guess at the problem after=20 examining the > headers a couple of days ago and seeing only the 'Basic' token and no > realm=3D"foo" parameter. So I changed the=20 <login-config> details to > contain the default realm definition but=20 unfortunately received > exactly the same error. Below is the request/response headers I saved > using livehttpheader :- > > http://localhost:7001/ros.bops.presentation.ui/ros/bops/presentation/ui/ > workflow/pageflows/begin.do > > GET > /ros.bops.presentation.ui/ros/bops/presentation/ui/workflow/pageflows/be > gin.do HTTP/1.1 > Host: localhost:7001 > User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-GB; rv:1.8.1.3) > Gecko/20070309 Firefox/2.0.0.3 > Accept: > text/xml,application/xml,application/xhtml+xml,text/html;q=3D0.9,text/pl > a= > i > n;q=3D0.8,image/png,*/*;q=3D0.5 > Accept-Language: en-gb,en;q=3D0.5 > Accept-Encoding: gzip,deflate > Accept-Charset: ISO-8859-1,utf-8;q=3D0.7,*;q=3D0.7 > Keep-Alive: 300 > Connection: keep-alive > Cookie: > JSESSIONID=3DdQpdG5KD1g22ytYt13tNq31fhWy8fTWrbTtpw3v5Tr2nCx1m4p4q!139797 > 4= > 5 > 74; > ADMINCONSOLESESSION=3DqjtwG5HZnyvY1w86JsPqxLJTxwpH8QztTG6FsmkKSNLHpRPSnj > 4= > 6 > !-442889654 > > HTTP/1.x 401 Unauthorized > Connection: close > Date: Wed, 08 Aug 2007 13:53:54 GMT > Content-Length: 1518 > Content-Type: text/html > WWW-Authenticate: Basic realm=3D"default" > X-Powered-By: Servlet/2.4 JSP/2.0 > ---------------------------------------------------------- > > Cheers, > > Ben _______________________________________________ WebTest mailing list [email protected] http://lists.canoo.com/mailman/listinfo/webtest

