Code

Changes between Version 2 and Version 3 of DjangoSpecifications/Contrib/Sessions


Ignore:
Timestamp:
04/04/08 05:14:53 (6 years ago)
Author:
anonymous
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • DjangoSpecifications/Contrib/Sessions

    v2 v3  
    11= Session framework improvements = 
    22 
    3 The following tickets call for improvements in session logic: #5549:comment:5, #2548, #3304, #1180, #6791, #6941. 
     3The following tickets call for improvements in session logic: comment:ticket:5549:5, #2548, #3304, #1180, #6791, #6941. 
    44Some of the tickets are interrelated, some of them pose security risks. 
    55Additionally, sessions are not thread-safe (see http://groups.google.com/group/django-users/browse_frm/thread/a7d42475b66530bd) and are missing a single method to destroy the session (ad-hoc workaround: iterate through all session keys and delete them one by one). 
     
    1818 * supports concurrency by using locking throughout (as Beaker does, think mod_wsgi with threads and AJAX), 
    1919 * supports destroying sessions (no dangling data nor session ID should remain), 
    20  * supports controlling session lifetime (#2548:comment:8 describes the use case), 
     20 * supports controlling session lifetime (comment:ticket:2548:8 describes the use case), 
    2121 * has a well-defined relationship to request.user. I haven't checked the code, but as far as I know, the user is stored in session. This is of course entirely reasonable, but the relationship should be documented to avoid overwriting the user key in session. The session should remain to be tied to browser (re: ''jacobkm: Also, there's the question of whether the session is tied to the browser or to the user -- we're a bit muddled there currently''), there should perhaps be a user-specific data bucket to store additional user-specific attributes if required that will represent a 'user session' -- something in the lines of `extra_attributes` dict.