Skip to content

Commit

Permalink
Issue #11738: Deprecate $g_session_key configuration option
Browse files Browse the repository at this point in the history
We don't need to use a unique 'session_key' configuration option anymore
as we can just derive a unique key from $g_crypto_master_salt.
  • Loading branch information
davidhicks committed Dec 25, 2010
1 parent b565be1 commit 1416aaf
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 8 deletions.
7 changes: 0 additions & 7 deletions config_defaults_inc.php
Expand Up @@ -234,13 +234,6 @@
*/
$g_session_handler = 'php';

/**
* Session key name. Should be unique between multiple installations to prevent
* conflicts.
* @global string $g_session_key
*/
$g_session_key = 'MantisBT';

/**
* Session save path. If false, uses default value as set by session handler.
* @global bool $g_session_save_path
Expand Down
1 change: 1 addition & 0 deletions core/obsolete.php
Expand Up @@ -155,3 +155,4 @@
config_obsolete( 'show_queries_threshold', 'show_log_threshold' );
config_obsolete( 'show_queries_list' );
config_obsolete( 'administrator_email', 'webmaster_email' );
config_obsolete( 'session_key' );
2 changes: 1 addition & 1 deletion core/session_api.php
Expand Up @@ -102,7 +102,7 @@ function __construct( $p_session_id=null ) {
global $g_cookie_secure_flag_enabled;
global $g_cookie_httponly_flag_enabled;

$this->key = config_get_global( 'session_key' );
$this->key = hash( 'whirlpool', 'session_key' . config_get_global( 'crypto_master_salt' ), true );

# Save session information where specified or with PHP's default
$t_session_save_path = config_get_global( 'session_save_path' );
Expand Down

0 comments on commit 1416aaf

Please sign in to comment.