summaryrefslogtreecommitdiffstats
path: root/core/authorize.php
diff options
context:
space:
mode:
authorAlex Pott2013-06-29 16:26:55 (GMT)
committerAlex Pott2013-06-29 16:26:55 (GMT)
commitaa9c2ccc856a248711c09caad84fb7638f9f217a (patch)
tree36450b13c8b286b00fc74602c705b4a0cba3d746 /core/authorize.php
parent30a45aded3cc64b322d2b8934a351da0ef0350f0 (diff)
Issue #1890878 by corvus_ch, ygerasimov, berenddeboer, Crell, fubhy the cat, effulgentsia: Add modular authentication system, including Http Basic; deprecate global .
Diffstat (limited to 'core/authorize.php')
-rw-r--r--core/authorize.php6
1 files changed, 4 insertions, 2 deletions
diff --git a/core/authorize.php b/core/authorize.php
index f347ba5..fe39394 100644
--- a/core/authorize.php
+++ b/core/authorize.php
@@ -48,10 +48,12 @@ function authorize_access_denied_page() {
* The killswitch in settings.php overrides all else, otherwise, the user must
* have access to the 'administer software updates' permission.
*
- * @return
+ * @return bool
* TRUE if the current user can run authorize.php, and FALSE if not.
*/
function authorize_access_allowed() {
+ require_once DRUPAL_ROOT . '/' . settings()->get('session_inc', 'core/includes/session.inc');
+ drupal_session_initialize();
return settings()->get('allow_authorize_operations', TRUE) && user_access('administer software updates');
}
@@ -65,7 +67,7 @@ require_once __DIR__ . '/includes/ajax.inc';
// We prepare only a minimal bootstrap. This includes the database and
// variables, however, so we have access to the class autoloader.
-drupal_bootstrap(DRUPAL_BOOTSTRAP_SESSION);
+drupal_bootstrap(DRUPAL_BOOTSTRAP_VARIABLES);
// This must go after drupal_bootstrap(), which unsets globals!
global $conf;