On 3/17/07, sebb <[EMAIL PROTECTED]> wrote:
On 17/03/07, robert lazarski <[EMAIL PROTECTED]> wrote:
> On 3/14/07, sebb <[EMAIL PROTECTED]> wrote:
> > On 14/03/07, robert lazarski <[EMAIL PROTECTED]> wrote:
> > > On 3/14/07, sebb <[EMAIL PROTECTED]> wrote:
> > > > On 14/03/07, robert lazarski <[EMAIL PROTECTED]> wrote:
> > You may need the referer (sic) header.
> >
> > > Cookie: JSESSIONID=8EF794277593CDAE19A765619417894C
> > > Content-Type: application/x-www-form-urlencoded
> > > Content-Length: 92
> > >
j_username=xxx%40yahoo.com&j_password=yyy1&submit.x=22&submit.y=9&submit=Login
> > > HTTP/1.x 302 Moved Temporarily
> > > Server: Apache-Coyote/1.1
> > > X-Powered-By: Servlet 2.4; JBoss-4.0.5.GA (build: CVSTag=Branch_4_0
> > > date=200610162339)/Tomcat-5.5
> > > Location: http://penguin.wazollc.net:8080/at/
> > > Content-Length: 0
> > > Date: Wed, 14 Mar 2007 17:13:58 GMT
> > > ----------------------------------------------------------
> > > http://penguin.myserver.net:8080/at/
> > >
> > > GET /at/ HTTP/1.1
> > > Host: penguin.wazollc.net:8080
> > > User-Agent: Mozilla/5.0 (X11; U; Linux i686; pt-BR; rv:1.8.1)
> > > Gecko/20061023 SUSE/2.0-30 Firefox/2.0
> > > Accept:
text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
> > > Accept-Language: en-us,pt-br;q=0.8,en;q=0.5,pt;q=0.3
> > > Accept-Encoding: gzip,deflate
> > > Accept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.7
> > > Keep-Alive: 300
> > > Connection: keep-alive
> > > Referer: http://penguin.myserver.net:8080/at/public/index.jsp
> > > Cookie: JSESSIONID=8EF794277593CDAE19A765619417894C
> > >
> > > HTTP/1.x 200 OK
> > > Server: Apache-Coyote/1.1
> > > X-Powered-By: Servlet 2.4; JBoss-4.0.5.GA (build: CVSTag=Branch_4_0
> > > date=200610162339)/Tomcat-5.5
> > >
>
> OK, I figured out how to pass the cookie via the url by teminating
> with ;jsessionid . So after logging in with this url and the
> parameters set:
>
> /at/j_acegi_security_check
>
> That returns a cookie. I can then send this url:
>
> /at/j_acegi_security_check;jsessionid=2434FB90D8E1983245436D0C517898BF
Which is not a cookie ...
>
> And it will acknowledge is was already authenticated. The problem:
> That won't work for the next data request. I can pass this url and it
> will indeed get past the authentication:
>
> /at/smartclient.form;jsessionid=2434FB90D8E1983245436D0C517898BF
>
> However, that will throw an exception because /at/smartclient.form is
> expecting params. For example, this would be ideal:
>
>
/at/smartclient.form?is_isc_rpc=true&isc_clientVersion=5.6b2&iscTNum=0;jsessionid=2434FB90D8E1983245436D0C517898BF
>
These are parameters; add them to the http request.
> but the authentication does not acknowledge the cookie. I cannot get
> the cookie manager to pass this cookie manually or automatically as
> done with ;jsession to indicate previous authentication to either the
> login or to smartclient.form.
>
> Any ideas?
If the value of jsessionid is expected by the server to be present in
the URL, then it is not using jsessionid as a cookie.
Have you looked at URL Rewriting:
http://jakarta.apache.org/jmeter/usermanual/component_reference.html#HTTP_URL_Re-writing_Modifier
HTTP_URL_Re-writing_Modifier seems to be working for the
authentication. However, there is some funky rpc thing going on inside
the proprietary rich client thing we are using. Here's what live
headers show when run from the browser. :
POST /at/smartclient.form?is_isc_rpc=true&isc_clientVersion=5.6b2&iscTNum=1
HTTP/1.1
Host: penguin.wazollc.net:8080
User-Agent: Mozilla/5.0 (X11; U; Linux i686; pt-BR; rv:1.8.0.6)
Gecko/20060728 SUSE/1.5.0.6-1.3 Firefox/1.5.0.6
Accept:
text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Accept-Language: pt-br,pt;q=0.8,en-us;q=0.5,en;q=0.3
Accept-Encoding: gzip,deflate
Accept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.7
Keep-Alive: 300
Connection: keep-alive
Referer: http://penguin.wazollc.net:8080/at/
Cookie: JSESSIONID=9F1CE84ADE39EE37157C88D16039FF23
Content-Type: application/x-www-form-urlencoded
Content-Length: 927
_transaction=%3Ctransaction+xmlns%3Axsi%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2F10%2FXMLSchema-instance%22+xsi%3Atype%3D%22xsd%3AObject%22%3E%3CtransactionNum+xsi%3Atype%3D%22xsd%3Along%22%3E1%3C%2FtransactionNum%3E%3Coperations+xsi%3Atype%3D%22xsd%3AList%22%3E%3Celem+xsi%3Atype%3D%22xsd%3AObject%22%3E%3Cwhere+xsi%3Atype%3D%22xsd%3AObject%22%3E%3CfundID+xsi%3Atype%3D%22xsd%3Along%22%3E14%3C%2FfundID%3E%3C%2Fwhere%3E%3CoperationConfig+xsi%3Atype%3D%22xsd%3AObject%22%3E%3CdataSource%3EFund%3C%2FdataSource%3E%3CoperationType%3Efetch%3C%2FoperationType%3E%3CtextMatchStyle%3Esubstring%3C%2FtextMatchStyle%3E%3C%2FoperationConfig%3E%3CappID%3EbuiltinApplication%3C%2FappID%3E%3Coperation%3EFund_fetch%3C%2Foperation%3E%3C%2Felem%3E%3C%2Foperations%3E%3Cjscallback%3Eparent.isc.RPCManager.performTransactionReply%281%2C+results%29%3B%3C%2Fjscallback%3E%3C%2Ftransaction%3E&protocolVersion=1.0&__iframeTarget__=isc_HiddenFrame_465
HTTP/1.x 200 OK
So my problem is by using jmeter's XML-RPC request I can't get it to
work with HTTP_URL_Re-writing_Modifier. I did set 'Content-Type:
application/x-www-form-urlencoded' as a header. Strangely to me, the
POST above sets a cookie.
Anyways, how one might set a cookie or rewrite the url to have
;jsession , using XML-RPC request?
Thanks sebb, very much appreciated,
Robert
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]