You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@jakarta.apache.org by bu...@apache.org on 2011/07/14 23:58:52 UTC

DO NOT REPLY [Bug 51512] New: Cookies aren't inserted into HTTP request with IPv6 Host header

https://issues.apache.org/bugzilla/show_bug.cgi?id=51512

             Bug #: 51512
           Summary: Cookies aren't inserted into HTTP request with IPv6
                    Host header
           Product: JMeter
           Version: 2.3.4
          Platform: All
        OS/Version: Linux
            Status: NEW
          Severity: normal
          Priority: P2
         Component: HTTP
        AssignedTo: notifications@jakarta.apache.org
        ReportedBy: hife.me@gmail.com
    Classification: Unclassified


Using Jmeter on a system with IPv6 addressing and brings to 
the issue: 
HTTP Cookies aren't inserted in the HTTP request. 
Using the same jmx-test, but with IPv4 addressing, everything works fine. 
The HTTP Requests are pretty much the same except for the Host header: 
IPv4: 
Host: 172.31.61.41:8123 
IPv6: 
Host: [2002::12]:8123 

It seems like there is a bug in the way cookies are stored/retrieved for 
IPv6 hosts. 

Note: I tried changing the Cookie Policy to all the possible values 
(rfc2965, etc.). It didn't help. 

Note2: tried CookieManager.check.cookies=false in jmeter.properties didn't
help.

Looks like there is no workaround for this bug.

== Details: ===

IPv4: 
-------- 
GET /xxx.xxx HTTP/1.1 
Connection: keep-alive 
User-Agent: Java/1.6.0_14 
Host: 172.31.61.44:8123 
Accept: text/html, image/gif, image/jpeg, *; q=.2, */*; q=.2 


-------- 
HTTP/1.1 200 OK 
Date: Fri, 08 Jul 2011 23:17:18 GMT 
Content-Length: 659 
Content-Type: text/html; charset=utf-8 
Set-Cookie: TS48550d=7c55fc5f609f3263a19d5bf56ba87e4adc1f801ce2a34e724e1744d9;
Path=/ 
Set-Cookie:
TS48550d_1=bf7c6f914d6181372dfe392362bf8dc4dc1f801ce2a34e7200c6c833d9e562f258;
Path=/ 

<html><head><style> 
    TABLE, TD { border: 3px solid black; border-collapse: collapse } 
</style></head> 
<body><table> 
    <TR><TD>path        </TD><TD>     /xxx.xxx</TD></TR> 
    <TR><TD>query       </TD><TD>     </TD></TR> 
    <TR><TD>method      </TD><TD>     GET</TD></TR> 
    <TR><TD>cookie      </TD><TD>     </TD></TR> 
    <TR><TD>content_type</TD><TD>     </TD></TR> 
    <TR><TD>content     </TD><TD>     </TD></TR> 
    <TR><TD>as_string   </TD><TD><PRE>GET /xxx.xxx HTTP/1.1 
Connection: keep-alive 
Accept: text/html, image/gif, image/jpeg, *; q=.2, */*; q=.2 
Host: 172.31.61.44:8123 
User-Agent: Java/1.6.0_14 

</PRE></TD></TR> 
</table></body></html> 

-------- 
GET /fff.zip HTTP/1.1 
Connection: keep-alive 
Cookie: TS48550d=7c55fc5f609f3263a19d5bf56ba87e4adc1f801ce2a34e724e1744d9;
TS48550d_1=bf7c6f914d6181372dfe392362bf8dc4dc1f801ce2a34e7200c6c833d9e562f258 
User-Agent: Java/1.6.0_14 
Host: 172.31.61.44:8123 
Accept: text/html, image/gif, image/jpeg, *; q=.2, */*; q=.2 



IPv6: 
-------- 
GET /xxx.xxx HTTP/1.1 
Connection: keep-alive 
User-Agent: Java/1.6.0_14 
Host: [2002::12]:8123 
Accept: text/html, image/gif, image/jpeg, *; q=.2, */*; q=.2 


-------- 
HTTP/1.1 200 OK 
Date: Fri, 08 Jul 2011 20:37:53 GMT 
Content-Length: 657 
Content-Type: text/html; charset=utf-8 
Set-Cookie: TS48550d=d1f940e9b0d067b9e4d9b7870a3b76fed46c8da98c8b21124e171f7e;
Path=/ 
Set-Cookie:
TS48550d_1=f2ca831a9781d3a13d30c433d2d18d43d46c8da98c8b211200c6c833d9e562f258;
Path=/ 

<html><head><style> 
    TABLE, TD { border: 3px solid black; border-collapse: collapse } 
</style></head> 
<body><table> 
    <TR><TD>path        </TD><TD>     /xxx.xxx</TD></TR> 
    <TR><TD>query       </TD><TD>     </TD></TR> 
    <TR><TD>method      </TD><TD>     GET</TD></TR> 
    <TR><TD>cookie      </TD><TD>     </TD></TR> 
    <TR><TD>content_type</TD><TD>     </TD></TR> 
    <TR><TD>content     </TD><TD>     </TD></TR> 
    <TR><TD>as_string   </TD><TD><PRE>GET /xxx.xxx HTTP/1.1 
Connection: keep-alive 
Accept: text/html, image/gif, image/jpeg, *; q=.2, */*; q=.2 
Host: [2002::12]:8123 
User-Agent: Java/1.6.0_14 

</PRE></TD></TR> 
</table></body></html> 

-------- 
GET /fff.zip HTTP/1.1 
Connection: keep-alive 
User-Agent: Java/1.6.0_14 
Host: [2002::12]:8123 
Accept: text/html, image/gif, image/jpeg, *; q=.2, */*; q=.2 

--------

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@jakarta.apache.org
For additional commands, e-mail: notifications-help@jakarta.apache.org


DO NOT REPLY [Bug 51512] Cookies aren't inserted into HTTP request with IPv6 Host header

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=51512

Philippe Mouawad <p....@ubik-ingenierie.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
  Attachment #27467|0                           |1
        is obsolete|                            |

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@jakarta.apache.org
For additional commands, e-mail: notifications-help@jakarta.apache.org


DO NOT REPLY [Bug 51512] Cookies aren't inserted into HTTP request with IPv6 Host header

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=51512

William A. Rowe Jr. <wr...@apache.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |INVALID

--- Comment #3 from William A. Rowe Jr. <wr...@apache.org> 2011-09-09 04:05:02 UTC ---
Cookies are stored by the client, not by the server.  Report this to your
client software project/vendor.  The server is sending proper set-cookie
headers and the client is ignoring them.

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@jakarta.apache.org
For additional commands, e-mail: notifications-help@jakarta.apache.org


DO NOT REPLY [Bug 51512] Cookies aren't inserted into HTTP request with IPv6 Host header

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=51512

Milamber <mi...@apache.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|RESOLVED                    |REOPENED
         Resolution|INVALID                     |

--- Comment #4 from Milamber <mi...@apache.org> 2011-09-09 08:11:47 UTC ---
The JMeter Cookie Manager uses HTTPClient API to validate/parse Cookie header. 

This bug is provide by Httpclient 3.1 which not support host with IPv6 address.
https://issues.apache.org/jira/browse/HTTPCLIENT-654

A workaround is use a host header with a name (not ip).

The fix is to use HTTPClient 4.x for cookie manager (I works on this).

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@jakarta.apache.org
For additional commands, e-mail: notifications-help@jakarta.apache.org


DO NOT REPLY [Bug 51512] Cookies aren't inserted into HTTP request with IPv6 Host header

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=51512

--- Comment #5 from Alex Gavrilov <hi...@gmail.com> 2011-09-22 23:39:05 UTC ---
Thanks Milamber!
I currently use hostnames, 
but it would be great to be able to run the traffic with IPv6 in the Host
header.
Looking forward for your fix.

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@jakarta.apache.org
For additional commands, e-mail: notifications-help@jakarta.apache.org


DO NOT REPLY [Bug 51512] Cookies aren't inserted into HTTP request with IPv6 Host header

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=51512

Milamber <mi...@apache.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Version|2.3.4                       |2.5.1
         OS/Version|Linux                       |All
           Severity|critical                    |major

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@jakarta.apache.org
For additional commands, e-mail: notifications-help@jakarta.apache.org


DO NOT REPLY [Bug 51512] Cookies aren't inserted into HTTP request with IPv6 Host header

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=51512

--- Comment #2 from Philippe Mouawad <p....@ubik-ingenierie.com> 2011-09-07 17:19:41 UTC ---
Sorry, attached patch is not for this issue,

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@jakarta.apache.org
For additional commands, e-mail: notifications-help@jakarta.apache.org


DO NOT REPLY [Bug 51512] Cookies aren't inserted into HTTP request with IPv6 Host header

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=51512

Alex Gavrilov <hi...@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Priority|P2                          |P1
           Severity|normal                      |critical

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@jakarta.apache.org
For additional commands, e-mail: notifications-help@jakarta.apache.org


DO NOT REPLY [Bug 51512] Cookies aren't inserted into HTTP request with IPv6 Host header

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=51512

--- Comment #1 from Philippe Mouawad <p....@ubik-ingenierie.com> 2011-09-07 17:14:10 UTC ---
Created attachment 27467
  --> https://issues.apache.org/bugzilla/attachment.cgi?id=27467
The fix to FunctionProperty#hashCode

The patch as described in previous comment
Philippe Mouawad

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@jakarta.apache.org
For additional commands, e-mail: notifications-help@jakarta.apache.org