Changeset 7090

Show
Ignore:
Timestamp:
11/26/08 10:04:55 (6 weeks ago)
Author:
inureyes
Message:

refs #1156

  • ACL 체크 루틴을 preprocessor로 이동
Location:
trunk
Files:
1 removed
2 modified

Legend:

Unmodified
Added
Removed
  • trunk/interface/login/openid/index.php

    r7072 r7090  
    1010    3. tryAuthURI: the entrance uri of openid authentication. 
    1111 */ 
     12 
     13define('__TEXTCUBE_ADMINPANEL__',true); 
    1214 
    1315$IV = array( 
  • trunk/library/preprocessor.php

    r7087 r7090  
    157157if(in_array($context->URLInfo['interfaceType'], array('owner','reader'))) { 
    158158    requireOwnership();     // Check access control list 
    159     require ROOT .'/library/pageACL.php'; 
     159    if(!empty($_SESSION['acl'])) { 
     160        $requiredPriv = Aco::getRequiredPrivFromUrl( $suri['directive'] ); 
     161        if( !empty($requiredPriv) && !Acl::check($requiredPriv) ) { 
     162            if( in_array( 'group.administrators', $requiredPriv ) ) { 
     163                header("location:".$blogURL ."/owner/center/dashboard"); exit; 
     164            } else { 
     165                header("location:".$blogURL ."/owner/entry"); exit; 
     166            } 
     167        } 
     168     
     169    } 
    160170} 
    161171?>