From 7181e466eb97d9a6fc575cd45312f739c408dee3 Mon Sep 17 00:00:00 2001 From: Florian Schlichting Date: Tue, 9 Jan 2018 00:49:54 +0100 Subject: [PATCH] DAVPrincipal->FetchProxyGroups(): invert arguments to pprivs() this needs to be the other way round than above --- inc/DAVPrincipal.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/inc/DAVPrincipal.php b/inc/DAVPrincipal.php index e2054eb3..f5e28b68 100644 --- a/inc/DAVPrincipal.php +++ b/inc/DAVPrincipal.php @@ -220,7 +220,7 @@ class DAVPrincipal extends Principal } } - $sql = 'SELECT principal_id, username, pprivs(:request_principal::int8,principal_id,:scan_depth::int) FROM principal JOIN usr USING(user_no) WHERE usr.active=true AND principal_id IN (SELECT * from grants_proxy_access_from_p(:request_principal,:scan_depth))'; + $sql = 'SELECT principal_id, username, pprivs(principal_id,:request_principal::int8,:scan_depth::int) FROM principal JOIN usr USING(user_no) WHERE usr.active=true AND principal_id IN (SELECT * from grants_proxy_access_from_p(:request_principal,:scan_depth))'; $qry = new AwlQuery($sql, $params ); // reuse $params assigned for earlier query if ( $qry->Exec('DAVPrincipal') && $qry->rows() > 0 ) { while( $relationship = $qry->Fetch() ) {