Skip to content

Commit

Permalink
Move admin access check to top of test_langs script
Browse files Browse the repository at this point in the history
The administrator access check was being performed a little too late in
the test_langs.php script. This could reveal potentially sensitive
information via error messages that are encountered before the admin
check.
  • Loading branch information
davidhicks committed Dec 15, 2010
1 parent d066f09 commit 51d4164
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions admin/test_langs.php
Expand Up @@ -29,6 +29,8 @@
*/
require_once( dirname( dirname( __FILE__ ) ) . DIRECTORY_SEPARATOR . 'core.php' );

access_ensure_global_level( config_get_global( 'admin_site_threshold' ) );

if( function_exists( 'xdebug_disable' ) ) {
xdebug_disable();
}
Expand All @@ -48,8 +50,6 @@
unset( $g_skip_lang_load ) ;
lang_push( 'english' );

access_ensure_global_level( config_get_global( 'admin_site_threshold' ) );

set_time_limit( 0 );

html_page_top();
Expand Down

0 comments on commit 51d4164

Please sign in to comment.