⌈⌋ ⎇ branch:  freshcode


Check-in [4ee9fb60b6]

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Make actual timeout for session also 7 days.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: 4ee9fb60b65de9b7c11eef8c3ff491f421e2d32c
User & Date: mario 2014-12-23 05:11:05
Context
2014-12-23
05:11
Prevent recollapsing of forum entries when editing within the reply/form fields. check-in: f8bc06e188 user: mario tags: trunk
05:11
Make actual timeout for session also 7 days. check-in: 4ee9fb60b6 user: mario tags: trunk
05:10
One-time SQL fixing scripts for submitter_image. check-in: aaf424b6b3 user: mario tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to lib/deferred_openid_session.php.

65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
function session_fresh() {

    // Initiate with current session identifier
    if ($_COOKIE->has("USER")) {
        session_id($_COOKIE->id["USER"]);
    }
    session_name("USER");
    session_set_cookie_params(0, "/", HTTP_HOST, false, true);
    session_start();

    // Security by obscurity: lock client against User-Agent
    $useragent = $_SERVER->text->length…30["HTTP_USER_AGENT"];
    // Security by obscurity: IP subnet lock (or just major route for IPv6)
    $subnet = $_SERVER->ip->length…6["REMOTE_ADDR"];
    // Server-side timeout (7 days)







|







65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
function session_fresh() {

    // Initiate with current session identifier
    if ($_COOKIE->has("USER")) {
        session_id($_COOKIE->id["USER"]);
    }
    session_name("USER");
    session_set_cookie_params(7*24*3600, "/", HTTP_HOST, false, true);
    session_start();

    // Security by obscurity: lock client against User-Agent
    $useragent = $_SERVER->text->length…30["HTTP_USER_AGENT"];
    // Security by obscurity: IP subnet lock (or just major route for IPv6)
    $subnet = $_SERVER->ip->length…6["REMOTE_ADDR"];
    // Server-side timeout (7 days)