Changeset 550

Show
Ignore:
Timestamp:
09/15/06 08:29:06 (2 years ago)
Author:
misja
Message:

Made the auth/ section behave more like the mod/ handling by making the authentication call unique to the module, e.g. internal_authenticate_user_login().

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • devel/auth/internal/lib.php

    r549 r550  
    11<?php 
    22// this is internal or default authentication 
    3 function authenticate_user_login($username,$password) { 
     3function internal_authenticate_user_login($username,$password) { 
    44     
    55    return get_record_select('users',"username = ? AND password = ? AND active = ? AND user_type = ? ", 
  • devel/lib/elgglib.php

    r528 r550  
    33933393     
    33943394    require_once($CFG->dirroot . 'auth/' . $CFG->auth . '/lib.php'); 
     3395 
     3396    // Module authentication function 
     3397    $function = $CFG->auth.'_authenticate_user_login'; 
     3398 
     3399    // Does the function exist 
     3400    if (!function_exists($function)) { 
     3401        print 'Error: function '.$function.' not found in auth/' . $CFG->auth . '/lib.php'; 
     3402        return false; 
     3403    } 
    33953404     
    3396     if (!$user = authenticate_user_login($username,$password)) { 
     3405    if (!$user = $function($username,$password)) { 
    33973406        return false; 
    33983407    }