Roxen.git / server / base_server / global_variables.pike

version» Context lines:

Roxen.git/server/base_server/global_variables.pike:1:   // This file is part of Roxen WebServer.   // Copyright © 1996 - 2004, Roxen IS. - // $Id: global_variables.pike,v 1.114 2008/09/29 15:57:33 mast Exp $ + // $Id: global_variables.pike,v 1.115 2009/01/08 23:14:46 mast Exp $      // #pragma strict_types   #define DEFVAR mixed...:object   #define BDEFVAR mixed...:object      #define IN_ROXEN   #include <module.h>   inherit "read_config";   inherit "basic_defvar";   #include <version.h>
Roxen.git/server/base_server/global_variables.pike:758:    "messages in Roxen. Standard means using "    "the default locale, which varies "    "according to the values of "    "the 'LC_MESSAGES' and 'LANG' environment "    "variables.")))    ->set_changed_callback( lambda(Variable.Variable s) {    roxenp()->set_default_locale(query("locale"));    roxenp()->set_locale();    } );    -  string secret=Crypto.MD5()->update(""+time(1)+random(100000))->digest(); +  string secret=Crypto.MD5.hash(""+time(1)+random(100000));    secret = MIME.encode_base64(secret,1);    defvar("server_salt", secret[..sizeof(secret)-3], LOCALE(8, "Server secret"),    TYPE_STRING|VAR_MORE|VAR_NO_DEFAULT,    LOCALE(9, "The server secret is a string used in some "    "cryptographic functions, such as calculating "    "unique, non-guessable session id's. Change this "    "value into something that is hard to guess, unless "    "you are satisfied with what your computers random "    "generator has produced.") );    -  secret = Crypto.MD5()->update(""+time(1)+random(100000)+"x"+gethrtime()) -  ->digest(); +  secret = Crypto.MD5.hash(""+time(1)+random(100000)+"x"+gethrtime());       definvisvar("argcache_secret","",TYPE_STRING|VAR_NO_DEFAULT);    set( "argcache_secret", secret );    // force save.          defvar("suicide_engage", 0,    LOCALE(160, "Auto Restart: Enable Automatic Restart"),    TYPE_FLAG|VAR_MORE,    LOCALE(161, "If set, Roxen will automatically restart after a "