[Freeipa-devel] [freeipa PR#532][comment] Fix cookie with Max-Age processing

stlaz freeipa-github-notification at redhat.com
Thu Mar 2 14:20:05 UTC 2017


  URL: https://github.com/freeipa/freeipa/pull/532
Title: #532: Fix cookie with Max-Age processing

stlaz commented:
"""
If I read the code well, in a well-set-up cookie, during `store_session_cookie()` when `Cookie.get_named_cookie_from_string()` is called, the expiration gets normalized which basically means removing the `Max-Age` attribute and replacing it with the `Expires` attribute in the cookie string (see `Cookie.normalize_expiration()` and `Cookie.__str__()`). When later retrieving the cookie, it should not have the `Max-Age` attribute anymore but only `Expires`. Therefore we need to calculate it or change the way `normalize_expiration()` behaves.
"""

See the full comment at https://github.com/freeipa/freeipa/pull/532#issuecomment-283665210


More information about the Freeipa-devel mailing list