28 if( ! isset( $cf[
'contents'][
'pages'][
$p ][
'auth'][
'groups'] ) || ( isset(
$_SESSION[
'account'][
'gruppi'] ) && count( array_intersect( $cf[
'contents'][
'pages'][ $p ][
'auth'][
'groups'],
$_SESSION[
'account'][
'gruppi'] ) ) > 0 ) ) {
47 logWrite(
'richiesta di accesso per ' .
$t .
'/' .
$a,
'auth', LOG_DEBUG );
53 if( isset(
$_SESSION[
'account'][
'permissions'][
$t ] ) ) {
56 $i[
'__auth__'] =
$_SESSION[
'account'][
'permissions'][
$t ];
62 logWrite(
'accesso consentito per ' . $t .
'/' . $a .
' -> ' . implode(
',',$i[
'__auth__'] ),
'auth', LOG_DEBUG );
68 logWrite(
'accesso non consentito per ' . $t .
'/' . $a .
' in ' . implode(
', ', $i[
'__auth__'] ),
'auth', LOG_ERR );
76 logWrite(
'accesso non consentito per ' . $t,
'auth', LOG_ERR );
94 logWrite(
'richiesta di accesso per ' .
$t .
'/' .
$id .
'/' .
$a,
'auth', LOG_DEBUG );
97 $i[
'__auth__'] =
$_SESSION[
'account'][
'permissions'][
$t ];
111 logWrite(
'accesso FULL per ' .
$t .
'/' .
$id .
'/' . $a,
'auth', LOG_DEBUG );
128 logWrite(
'accesso FULL non consentito per ' .
$t .
'/' .
$id .
'/' . $a .
' procedo con le verifiche',
'auth', LOG_DEBUG );
135 if( empty( $aclTb ) ) {
141 logWrite(
'nessuna tabella di ACL presente per ' .
$t .
', autorizzazione concessa',
'auth', LOG_DEBUG );
197 "SELECT concat_ws( ',', group_concat( ${aclTb}.permesso SEPARATOR ',' ), if( ( ${t}_view.id_account_inserimento = ? OR ${t}_view.id_account_editor = ? ), 'FULL', NULL ) ) AS t ".
199 "LEFT JOIN ${aclTb} ON ${aclTb}.id_entita = ${t}_view.id ".
200 # NON GERARCHICO
"LEFT JOIN account_gruppi ON account_gruppi.id_gruppo = ${aclTb}.id_gruppo ".
201 "LEFT JOIN account_gruppi ON ( account_gruppi.id_gruppo = ${aclTb}.id_gruppo OR gruppi_path_check( ${aclTb}.id_gruppo, account_gruppi.id_gruppo ) ) ".
202 # NON CONSIDERA EDITOR
"WHERE ( account_gruppi.id_account = ? OR ${t}_view.id_account_inserimento = ? ) ".
203 "WHERE ( account_gruppi.id_account = ? OR ${t}_view.id_account_inserimento = ? OR ${t}_view.id_account_editor = ? ) ".
204 "AND ${t}_view.id = ? ",
205 # NON CONSIDERA EDITOR array( array(
's' => $aclId ), array(
's' => $aclId ), array(
's' => $aclId ), array(
's' =>
$id ) )
206 array( array(
's' => $aclId ), array(
's' => $aclId ), array(
's' => $aclId ), array(
's' => $aclId ), array(
's' => $aclId ), array(
's' =>
$id ) )
209 $i[
'__auth__'] = explode(
',',
$r );
223 logWrite(
'permessi presenti sulla tabella di ACL per ' .
$t .
'/' .
$id .
'/' . $a .
', autorizzazione concessa',
'auth', LOG_DEBUG );
231 logWrite(
'permessi NON presenti sulla tabella di ACL per ' .
$t .
'/' .
$id .
'/' . $a .
' in (' .
$r .
'), autorizzazione negata',
'auth', LOG_DEBUG );
286 if(
$_SESSION[
'account'][
'username'] !=
'root' && ! in_array(
'roots',
$_SESSION[
'account'][
'gruppi'] ) ) {
289 # $r = mysqlSelectCachedValue( 292 "SELECT table_name FROM information_schema.tables WHERE table_name = '__acl_${t}__' AND table_schema = database()" 296 logWrite(
$_SESSION[
'account'][
'username'] .
' (' . implode(
',',
$_SESSION[
'account'][
'gruppi']) .
') tabella di ACL ' .
$r .
' trovata per ' .
$t,
'auth', LOG_DEBUG );
304 logWrite(
'accesso non filtrato concesso a ' .
$_SESSION[
'account'][
'username'] .
' (' . implode(
',',
$_SESSION[
'account'][
'gruppi']) .
') per ' .
$t,
'auth', LOG_DEBUG );
logWrite( $m, $f='site', $l=LOG_NOTICE, $d=DIRECTORY_LOG, $t=CURRENT_LOG_LEVEL, $s=SITE_STATUS)
scrive un messaggio nei log del sito
$cf['ricerca']['template']
getAclRightsTable( $c, $t)
if(isset( $_REQUEST['amazonCheckoutSessionId'])) $_SESSION['carrello']
getAclPermission( $t, $a, &$i=NULL)
getAclRights( $c, $t, $a, $id, &$i=NULL)