1. 12 Dec, 2017 1 commit
    • Marcus Boon's avatar
      MDL-59866 session: Add retry for redis sessions · f8e2383b
      Marcus Boon authored
      There is an edge case whereby redis will fail
      to accept connections on the first try but
      retrying the connection seems to make it work
      
      Included in this commit:
      * Retry functionality in the session init
      f8e2383b
  2. 24 Oct, 2017 2 commits
  3. 27 Mar, 2017 1 commit
  4. 13 Feb, 2017 1 commit
  5. 25 Jan, 2017 1 commit
  6. 10 Nov, 2016 2 commits
  7. 08 Nov, 2016 1 commit
    • David Monllaó's avatar
      MDL-54751 course: Set adhoc task user · 44eb1490
      David Monllaó authored
      We should complete the deletion process using the same
      user that started it.
      
      Added a new param to loginas() to prevent the event to be generated as
      there is no need to generate an new event for that as the user didn't
      explicitly loginas again.
      44eb1490
  8. 27 Oct, 2016 1 commit
  9. 24 Oct, 2016 1 commit
    • Andrew Nicols's avatar
      MDL-56129 core: Set a timeout on the session cookie · c823bfee
      Andrew Nicols authored
      This is primarily because iOS has changed something under the hood which
      means that only session cookies which have an expiry are passed around the
      OS.
      
      In order to make media playable outside of the browser (e.g. a video), we
      must set a session cookie timeout.
      
      Since the session timeout is configurable, this patch sets the cookie
      timeout to the session timeout plus a period of one week.
      
      This ensures that videos continue to work, and that the expired session
      message is shown on the login page, but without requiring excessively long
      session times.
      c823bfee
  10. 22 Aug, 2016 1 commit
  11. 04 Aug, 2016 1 commit
  12. 07 Jun, 2016 1 commit
  13. 06 May, 2016 2 commits
  14. 18 Apr, 2016 1 commit
    • Nicholas Hoobin's avatar
      MDL-53599 session: Added a session_class_handler for Redis. · c5211882
      Nicholas Hoobin authored
      It is now possible to set up Redis as a session handler for Moodle.
      Ensure that the phpredis extension is enabled and working on your sever.
      
      Please place the following lines in config.php
      $CFG->session_handler_class = '\core\session\redis';
      $CFG->session_redis_save_path = 'tcp://127.0.0.1';
      
      To determine if it has been set correctly, navigate to
      $CFG->wwwroot/admin/phpinfo.php and find following the strings in the
      session block,
      
      session.save_handler = redis
      session.save_path = tcp://127.0.0.1
      c5211882
  15. 02 Mar, 2016 1 commit
  16. 29 Feb, 2016 1 commit
  17. 28 Aug, 2015 1 commit
  18. 27 Jul, 2015 1 commit
  19. 25 Feb, 2015 1 commit
  20. 16 Dec, 2014 1 commit
    • Andrew Nicols's avatar
      MDL-44642 session: Add a client-side session keepalive system · 57996fe9
      Andrew Nicols authored
      For pages where there will be significant user interaction in which the
      server is not updated, it may be necessary to poll the server periodically
      to touch the session.
      
      This makes use of the existing checknet script which was designed for
      checking network connectivity but fits into this use-case reasonably well.
      57996fe9
  21. 21 Nov, 2014 1 commit
  22. 18 Nov, 2014 1 commit
  23. 03 Oct, 2014 1 commit
  24. 07 Aug, 2014 2 commits
  25. 05 Aug, 2014 1 commit
  26. 01 Jul, 2014 1 commit
    • Petr Skoda's avatar
      MDL-46099 session: fix use of references for session globals · 2e00d01d
      Petr Skoda authored
      This reverses the references used for global $USER and $SESSION,
      the reason is that PHP does not allow references to references.
      $USER is a reference to $GLOBALS['USER'] which means we cannot
      put any references to it. Solution is to store the current user and session
      objects in $GLOBALS['USER'] and $GLOBALS['SESSIOn'] are reference
      them in $_SESSION.
      
      This patch makes the session code behave the same way in CLI,
      phpunit and normal web requests - this allows use to finally
      unit test most aspects of the session code in Moodle.
      2e00d01d
  27. 24 Apr, 2014 1 commit
  28. 01 Apr, 2014 1 commit
    • sam marshall's avatar
      MDL-43975 Sessions: Should support memcache, not just memcached · e645b4d5
      sam marshall authored
      This commit adds a session handler which works using memcache (without
      requiring the memcached extension), similar to the support for
      memcache within MUC.
      
      This may be less reliable than memcached but we have been using a
      similar approach on our system without problems. In case, I added a
      warning in config-dist.php.
      e645b4d5
  29. 30 Nov, 2013 1 commit
  30. 29 Nov, 2013 1 commit
  31. 07 Nov, 2013 1 commit
  32. 27 Oct, 2013 1 commit
  33. 04 Oct, 2013 1 commit
  34. 24 Sep, 2013 1 commit
  35. 21 Sep, 2013 1 commit
    • Petr Škoda's avatar
      MDL-31501 rework user session architecture · d79d5ac2
      Petr Škoda authored
      List of changes:
       * New OOP API using PHP namespace \core\session\.
       * All handlers now update the sessions table consistently.
       * Experimental DB session support in Oracle.
       * Full support for session file handler (filesystem locking required).
       * New option for alternative session directory.
       * Official memcached session handler support.
       * Workaround for memcached version with non-functional gc.
       * Improved security - forced session id regeneration.
       * Improved compatibility with recent PHP releases.
       * Fixed borked CSS during install in debug mode.
       * Switched to file based sessions in new installs.
       * DB session setting disappears if DB does not support sessions.
       * DB session setting disappears if session handler specified in config.php.
       * Fast purging of sessions used in request only.
       * No legacy distinction -  file, database and memcached support the same functionality.
       * Session handler name included in performance info.
       * Fixed user_loggedin and use...
      d79d5ac2