module WebAgent::CookieUtils
def domain_match(host, domain)
case domain
when /\d+\.\d+\.\d+\.\d+/
return (host == domain)
when '.'
return true
when /^\./ #return tail_match?(domain, host)
return tail_match?(host, domain)
else
return (host == domain)
end
end
end
without this fix cookies do not round trip as they are not found by
Cookie#find.
regards.
-a
···
--
email :: ara [dot] t [dot] howard [at] noaa [dot] gov
phone :: 303.497.6469
anything that contradicts experience and logic should be abandoned.
-- h.h. the 14th dalai lama
I want to be sure that this release fixes bugs and does not break user
applications.
Hi,
I would like to encourage you to drop the "2" from the package name. Is
there a "1" and is "1" in common use? Also I encourage you to move
Cookie out of WebAgent namespace since it is no longer part of the
TAKAHASHI `Maki' Masayoshi's WebAgent program.
I would like to encourage you to drop the "2" from the package name. Is
there a "1" and is "1" in common use? Also I encourage you to move
There was "http-access" package by Maehashi-san. Unfortunately the
author terminated(?) it. Net::HTTP and http-access2 were children of
the package. As far as I know Net::HTTP was almost rewritten but
http-access2 still contains HTTP/1.1 parsing state machine of http-access.
Aside from this, I'll change package name and class name if I find a
good name. What do you think "SOAP::HTTPClient"?
Cookie out of WebAgent namespace since it is no longer part of the
TAKAHASHI `Maki' Masayoshi's WebAgent program.
I just applied patches from users to WebAgent::Cookie. I almost did
nothing. But I agree with you its module name should be changed. If I
find a good name...
> I would like to encourage you to drop the "2" from the package name. Is
> there a "1" and is "1" in common use? Also I encourage you to move
There was "http-access" package by Maehashi-san. Unfortunately the
author terminated(?) it. Net::HTTP and http-access2 were children of
the package. As far as I know Net::HTTP was almost rewritten but
http-access2 still contains HTTP/1.1 parsing state machine of http-access.
I see. Thanks.
Well, I'm no expert on these matters, but...
Aside from this, I'll change package name and class name if I find a
good name. What do you think "SOAP::HTTPClient"?
SOAP? More like REST::HTTPClient ?
But maybe just use HTTP namespace? HttpClient = HTTP::Client?
> Cookie out of WebAgent namespace since it is no longer part of the
> TAKAHASHI `Maki' Masayoshi's WebAgent program.
I just applied patches from users to WebAgent::Cookie. I almost did
nothing. But I agree with you its module name should be changed. If I
find a good name...
I definitely think HTTP::Cookie in this case is appropraite.
Aside from this, I'll change package name and class name if I find a
good name. What do you think "SOAP::HTTPClient"?
SOAP? More like REST::HTTPClient ?
Users seem to use http-access2 for (1)soap4r or (2)HTTP-Cookies
handling. Don't you think it's unrestful?
But maybe just use HTTP namespace? HttpClient = HTTP::Client?
Hmm. Too generic I think. Implementing HTTP protocol is preserved for
Net::HTTP. Handling HTTP resources is for open-uri. I hope
http-access2 used for creating HTTP client agent.
Trans wrote:
>> Aside from this, I'll change package name and class name if I find a
>> good name. What do you think "SOAP::HTTPClient"?
>
> SOAP? More like REST::HTTPClient ?
Users seem to use http-access2 for (1)soap4r or (2)HTTP-Cookies
handling. Don't you think it's unrestful?
Huh. Like I said I'm no expert. I didn't realize you could use it like
that. I use it to build a sort-of web-api to Rubyforge. I thought REST
b/c of that --no SOAP envelopes involved..
> But maybe just use HTTP namespace? HttpClient = HTTP::Client?
Hmm. Too generic I think. Implementing HTTP protocol is preserved for
Net::HTTP. Handling HTTP resources is for open-uri. I hope
http-access2 used for creating HTTP client agent.