Issue 991258: Cookie.py loses 'secure' attribute (original) (raw)

Issue991258

Created on 2004-07-14 23:50 by zenzen, last changed 2022-04-11 14:56 by admin. This issue is now closed.

Messages (2)
msg21615 - (view) Author: Stuart Bishop (zenzen) Date: 2004-07-14 23:50
SimpleCookie.load() happily parses a string with the 'secure' attribute, but loses it >>> c = SimpleCookie() >>> c['foo'] = 'bar' >>> c['foo']['secure'] = True >>> str(c) 'Set-Cookie: foo=bar; secure;' >>> c = SimpleCookie(str(c)) >>> str(c) 'Set-Cookie: foo=bar;' >>> c['foo']['secure'] ''
msg21616 - (view) Author: Stuart Bishop (zenzen) Date: 2004-07-15 01:05
Logged In: YES user_id=46639 I think this is my misunderstanding - load() is designed to parse Cookie: headers from the client, and 'secure' only ever appears in Set-Cookie: headers from the server.
History
Date User Action Args
2022-04-11 14:56:05 admin set github: 40568
2004-07-14 23:50:30 zenzen create