Re: Is this a bug? Cookies are in the Request Body...
Am 16.07.22 um 15:56 schrieb Robin D. Wilson: I see the same thing I saw on my test. When I tried your simplified test with 2 requests to"https://www.google.com;... Here's my setup: Test Plan Cookie Manager Thread Group HTTP Request (https://www.google.com) HTTP Request (https://www.google.com) View Results Tree The 2nd request's "Request Headers" look like this (no "Cookie:" header): Connection: keep-alive Host:www.google.com User-Agent: Apache-HttpClient/4.5.13 (Java/1.8.0_333) But the second request's "Request Body" looks like this: GEThttps://www.google.com/ GET data: Cookie Data: 1P_JAR=2022-07-16-13; AEC= It is the "Cookie Data:" in the request body that is confusing me (and the corresponding lack of a "Cookie:" request header). I was under the impression that there needed to be a 'cookie:' header for the server to see the cookie... If I switch the View Results Tree to show the HTTP view of the request instead of the "Raw" view - it does show the cookie as a request header. So is this just a goofy way the View Results Tree shows the output, or is this a bug? Yes, this is a bit strange. The cookies are not considered to be headers (you are most likely not setting them by hand) and are not reported, when you ask a sampleresult for its headers. The HTTP view knows, that it is displaying a HTTPSamplerResult, which can be asked for its cookies. Those cookies are then parsed and re-inserted as headers. To be more consistent, it might be a good idea to split the table into headers and cookies. But for the Raw view we can't ask the SampleResult for its Cookies, as the component is in the wrong package in the sources. That would need a bit more logic. Sorry. If you think this is too upsetting, raise an enhancement bug. Felix -- Robin D. Wilson CELL: 512-426-3929 rwils...@gmail.com On Sat, Jul 16, 2022 at 5:57 AM Felix Schumacher < felix.schumac...@internetallee.de> wrote: Without seeing your test, it is a bit difficult to answer without guessing. Guessing, I would say, the cookie has a secure flag set and you are using http (which is not considered secure). Try a simple test case for yourself, add a cookie manager, a view results tree and two samplers towww.google.com (get, no parameters needed). Run it. You should see the cookie data in the request tab of the second sampler. Felix Am 15.07.22 um 01:08 schrieb Robin D. Wilson: I have set up a Cookie Manager config element in my Test Plan. I am not seeing the 'cookie:' header value in my request. I'm using a 'View Results Tree' to view the request/response for a simple HTTP request series that has a cookie being set. If I look at the 'Raw' Text request data, I see no 'Cookie:' header in the Request Headers, but I see a "Cookie Data:" section in the "Request Body" section. I was under the impression that Cookie was a 'header' in the HTTP request. I've only seen cookies set with the "Cookie:" header, so I'm not sure what I'm misunderstanding here... -- Robin D. Wilson CELL:512-426-3929rwils...@gmail.com OpenPGP_0xEA6C3728EA91C4AF.asc Description: OpenPGP public key OpenPGP_signature Description: OpenPGP digital signature
Re: Is this a bug? Cookies are in the Request Body...
I'm so curious that I gave it a try myself, but I don't see the reported problem. Everything looks fine to me. One thing though, I put the Cookie Manager within Thread Group, not outside of it and under the Test Plan. If trying that still won't work for you, I'm afraid that you need to post your simple .jmx file somewhere, and tell us which JMeter version that you're using. On Sat, Jul 16, 2022 at 9:57 AM Robin D. Wilson wrote: > I see the same thing I saw on my test. When I tried your simplified test > with 2 requests to "https://www.google.com;... Here's my setup: > > Test Plan > Cookie Manager > Thread Group > HTTP Request (https://www.google.com) > HTTP Request (https://www.google.com) > View Results Tree > > The 2nd request's "Request Headers" look like this (no "Cookie:" header): > Connection: keep-alive > Host: www.google.com > User-Agent: Apache-HttpClient/4.5.13 (Java/1.8.0_333) > > But the second request's "Request Body" looks like this: > > GET https://www.google.com/ > > GET data: > > Cookie Data: > 1P_JAR=2022-07-16-13; AEC= > > > It is the "Cookie Data:" in the request body that is confusing me (and the > corresponding lack of a "Cookie:" request header). I was under the > impression that there needed to be a 'cookie:' header for the server to see > the cookie... If I switch the View Results Tree to show the HTTP view of > the request instead of the "Raw" view - it does show the cookie as a > request header. So is this just a goofy way the View Results Tree shows the > output, or is this a bug? > > -- > Robin D. Wilson > CELL: 512-426-3929 > rwils...@gmail.com > > > On Sat, Jul 16, 2022 at 5:57 AM Felix Schumacher < > felix.schumac...@internetallee.de> wrote: > > > Without seeing your test, it is a bit difficult to answer without > guessing. > > > > Guessing, I would say, the cookie has a secure flag set and you are using > > http (which is not considered secure). > > > > Try a simple test case for yourself, add a cookie manager, a view results > > tree and two samplers to www.google.com (get, no parameters needed). Run > > it. You should see the cookie data in the request tab of the second > sampler. > > > > Felix > > Am 15.07.22 um 01:08 schrieb Robin D. Wilson: > > > > I have set up a Cookie Manager config element in my Test Plan. > > > > I am not seeing the 'cookie:' header value in my request. I'm using a > 'View > > Results Tree' to view the request/response for a simple HTTP request > series > > that has a cookie being set. If I look at the 'Raw' Text request data, I > > see no 'Cookie:' header in the Request Headers, but I see a "Cookie > Data:" > > section in the "Request Body" section. I was under the impression that > > Cookie was a 'header' in the HTTP request. > > > > I've only seen cookies set with the "Cookie:" header, so I'm not sure > what > > I'm misunderstanding here... > > > > -- > > Robin D. Wilson > > CELL: 512-426-3929rwils...@gmail.com > > > > >
Re: Is this a bug? Cookies are in the Request Body...
I see the same thing I saw on my test. When I tried your simplified test with 2 requests to "https://www.google.com;... Here's my setup: Test Plan Cookie Manager Thread Group HTTP Request (https://www.google.com) HTTP Request (https://www.google.com) View Results Tree The 2nd request's "Request Headers" look like this (no "Cookie:" header): Connection: keep-alive Host: www.google.com User-Agent: Apache-HttpClient/4.5.13 (Java/1.8.0_333) But the second request's "Request Body" looks like this: GET https://www.google.com/ GET data: Cookie Data: 1P_JAR=2022-07-16-13; AEC= It is the "Cookie Data:" in the request body that is confusing me (and the corresponding lack of a "Cookie:" request header). I was under the impression that there needed to be a 'cookie:' header for the server to see the cookie... If I switch the View Results Tree to show the HTTP view of the request instead of the "Raw" view - it does show the cookie as a request header. So is this just a goofy way the View Results Tree shows the output, or is this a bug? -- Robin D. Wilson CELL: 512-426-3929 rwils...@gmail.com On Sat, Jul 16, 2022 at 5:57 AM Felix Schumacher < felix.schumac...@internetallee.de> wrote: > Without seeing your test, it is a bit difficult to answer without guessing. > > Guessing, I would say, the cookie has a secure flag set and you are using > http (which is not considered secure). > > Try a simple test case for yourself, add a cookie manager, a view results > tree and two samplers to www.google.com (get, no parameters needed). Run > it. You should see the cookie data in the request tab of the second sampler. > > Felix > Am 15.07.22 um 01:08 schrieb Robin D. Wilson: > > I have set up a Cookie Manager config element in my Test Plan. > > I am not seeing the 'cookie:' header value in my request. I'm using a 'View > Results Tree' to view the request/response for a simple HTTP request series > that has a cookie being set. If I look at the 'Raw' Text request data, I > see no 'Cookie:' header in the Request Headers, but I see a "Cookie Data:" > section in the "Request Body" section. I was under the impression that > Cookie was a 'header' in the HTTP request. > > I've only seen cookies set with the "Cookie:" header, so I'm not sure what > I'm misunderstanding here... > > -- > Robin D. Wilson > CELL: 512-426-3929rwils...@gmail.com > >
Re: Is this a bug? Cookies are in the Request Body...
Without seeing your test, it is a bit difficult to answer without guessing. Guessing, I would say, the cookie has a secure flag set and you are using http (which is not considered secure). Try a simple test case for yourself, add a cookie manager, a view results tree and two samplers to www.google.com (get, no parameters needed). Run it. You should see the cookie data in the request tab of the second sampler. Felix Am 15.07.22 um 01:08 schrieb Robin D. Wilson: I have set up a Cookie Manager config element in my Test Plan. I am not seeing the 'cookie:' header value in my request. I'm using a 'View Results Tree' to view the request/response for a simple HTTP request series that has a cookie being set. If I look at the 'Raw' Text request data, I see no 'Cookie:' header in the Request Headers, but I see a "Cookie Data:" section in the "Request Body" section. I was under the impression that Cookie was a 'header' in the HTTP request. I've only seen cookies set with the "Cookie:" header, so I'm not sure what I'm misunderstanding here... -- Robin D. Wilson CELL: 512-426-3929 rwils...@gmail.com OpenPGP_0xEA6C3728EA91C4AF.asc Description: OpenPGP public key OpenPGP_signature Description: OpenPGP digital signature
Is this a bug? Cookies are in the Request Body...
I have set up a Cookie Manager config element in my Test Plan. I am not seeing the 'cookie:' header value in my request. I'm using a 'View Results Tree' to view the request/response for a simple HTTP request series that has a cookie being set. If I look at the 'Raw' Text request data, I see no 'Cookie:' header in the Request Headers, but I see a "Cookie Data:" section in the "Request Body" section. I was under the impression that Cookie was a 'header' in the HTTP request. I've only seen cookies set with the "Cookie:" header, so I'm not sure what I'm misunderstanding here... -- Robin D. Wilson CELL: 512-426-3929 rwils...@gmail.com