RFC 2965 cookies, cookielib, and mailman.
John J Lee
jjl at pobox.com
Sun Jan 30 17:19:23 EST 2005
Just noticed your c.l.py post quoted below. Nobody but me knows or cares
about this obscure stuff ;-) so I'm not surprised you got no answer...
C. Titus Brown Dec 27 2004, 12:41 pm wrote:
> The issue turned out to be that mailman sends out RFC 2965  cookies,
> which are by default rejected by cookielib. I don't remotely pretend to
> understand the issues involved; hence my post ;).
> A few questions for those more clued in than me:
> * what is the difference between RFC 2965 cookies and others?
See "Where can I find out more about the HTTP cookie protocol?" here:
For both very short, slightly longer (first link in that section, to a
section of the ClientCookie docs on the cookie standards), and
insanely detailed (Kristol's paper) explanations.
> * why would mailman implement RFC 2965 cookies over the old format?
> (I'm guessing simply because it's the latest/best/format?)
Because Barry didn't realise that almost no browsers implement it (and
never will), I guess.
> * why would cookielib NOT accept RFC 2965 cookies by default?
See above: browsers don't implement it. It's essentially dead as an
internet standard. The only real standard is "what IE and Mozilla
do", plus some wisdom from RFCs 2109, 2965 and (more readably!) 2964.
> In any case, the way to make the cookielib example work for mailman is
> like so:
> policy = cookielib.DefaultCookiePolicy(rfc2965=True)
> cj = cookielib.LWPCookieJar('cookies.lwp', policy=policy)
Hmm, cookielib should work if IE and Mozilla do, so that's a bug :(
You shouldn't need to turn on 2965 handling.
Do you have a script that demonstrates the problem, so I can fix it?
More information about the Python-list