From b6d94b46e0bad17bfae80a4a3da1918eea76e9d7 Mon Sep 17 00:00:00 2001 From: Mark Crane Date: Fri, 26 Dec 2014 07:08:05 +0000 Subject: [PATCH] Check for permissions that have a null domain_uuid. --- resources/check_auth.php | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/resources/check_auth.php b/resources/check_auth.php index 038105b0b1..1bd2493fea 100644 --- a/resources/check_auth.php +++ b/resources/check_auth.php @@ -17,7 +17,7 @@ The Initial Developer of the Original Code is Mark J Crane - Portions created by the Initial Developer are Copyright (C) 2008-2013 + Portions created by the Initial Developer are Copyright (C) 2008-2014 the Initial Developer. All Rights Reserved. Contributor(s): @@ -307,11 +307,12 @@ require_once "resources/require.php"; foreach($_SESSION["groups"] as $field) { if (strlen($field['group_name']) > 0) { if ($x == 0) { - $sql .= "where (domain_uuid = '".$domain_uuid."' and group_name = '".$field['group_name']."') "; + $sql .= "where (domain_uuid = '".$domain_uuid."' and domain_uuid = null) "; } else { - $sql .= "or (domain_uuid = '".$domain_uuid."' and group_name = '".$field['group_name']."') "; + $sql .= "or (domain_uuid = '".$domain_uuid."' and domain_uuid = null) "; } + $sql .= "or group_name = '".$field['group_name']."' "; $x++; } }