This piece of code I found in somone elses work (can't recall who's off the top of my head), but I thought I should share it just in case it really is a bug -- It indicates that the domain and host are in the wrong order for the tail_match? call.
# fixes http-access2 bug
BEGIN {
require "http-access2"
module WebAgent::CookieUtils?
def domain_match(host, domain)
case domain
when /\d+\.\d+\.\d+\.\d+/
return (host == domain)
when '.'
return true
when /\./
# HERE!!!
#return tail_match?(domain, host)
return tail_match?(host, domain)
else
return (host == domain)
end
end
end
}