AnyEvent::HTTP and "bad" cookies
Marc Lehmann
schmorp at schmorp.de
Sun Jun 20 13:33:51 CEST 2010
On Sun, Jun 20, 2010 at 02:24:55PM +0400, Mons Anderson <mons at cpan.org> wrote:
> > 2. Cookies with values "0" are parsed as undef
>
> Oh, really, I forgot to note this issue.
Indeed, this comes likely from swapping the regex parts (before it checked
for the ""-string).
> > s/(expires\s*=\s*)([^";]*GMT)/$1"$2"/gi; #TODO: review
>
> As for me, I don't like unnecessary additional scan and rewrite of the
> whole cookie header.
> The mysterious cookie date could be included into the main regexp.
Neither of these regexes follows the new rfc though, so you should first
decide what your goals are - replace the correct regex by something
random? I doubt "browsers" do it that way...
--
The choice of a Deliantra, the free code+content MORPG
-----==- _GNU_ http://www.deliantra.net
----==-- _ generation
---==---(_)__ __ ____ __ Marc Lehmann
--==---/ / _ \/ // /\ \/ / schmorp at schmorp.de
-=====/_/_//_/\_,_/ /_/\_\
More information about the anyevent
mailing list