hc-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Oleg Kalnichevski (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (HTTPCLIENT-1614) Domain processing incompatible with 4.3.6
Date Mon, 16 Feb 2015 20:31:11 GMT

    [ https://issues.apache.org/jira/browse/HTTPCLIENT-1614?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14323244#comment-14323244

Oleg Kalnichevski commented on HTTPCLIENT-1614:

This is done per requirement of RFC 6265, section

{noformat}  The Domain Attribute


      WARNING: Some existing user agents treat an absent Domain
      attribute as if the Domain attribute were present and contained
      the current host name.  For example, if example.com returns a Set-
      Cookie header without a Domain attribute, these user agents will
      erroneously send the cookie to www.example.com as well.

If you need to reconstruct a cookie from a persistent store, you also need to persist the
original set of attributes sent by the origin server, not just effective attributes. 


> Domain processing incompatible with 4.3.6
> -----------------------------------------
>                 Key: HTTPCLIENT-1614
>                 URL: https://issues.apache.org/jira/browse/HTTPCLIENT-1614
>             Project: HttpComponents HttpClient
>          Issue Type: Bug
>          Components: HttpClient
>    Affects Versions: 4.4 Final
>            Reporter: Ronald Brill
> Hi Oleg,
> last week we have updated HtmlUnit (SNAPSHOT) from 4.3.6 to 4.4. During that we noticed
a major difference. After some debugging i guess i found the reason.
> The BasicDomainHandler#match impl checks for the existence of a attribute (DOMAIN_ATTR).
Because we are building our own the cookies (using the constructur and some getter/setter
and not parsing some headers), the attrib map is empty. But of course the domain attribute
is set.
> It will help, if the match impl will check the real fields instead of the attrib map.
Additionally this will be more consistent because the domainMatch method already uses the
domain field and not the value from the attrib map.
> What do you think?

This message was sent by Atlassian JIRA

To unsubscribe, e-mail: dev-unsubscribe@hc.apache.org
For additional commands, e-mail: dev-help@hc.apache.org

View raw message