]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
Author: Isnard <isnardjaquet@gmail.com>
authorAmos Jeffries <squid3@treenet.co.nz>
Sat, 18 Jul 2009 04:06:25 +0000 (16:06 +1200)
committerAmos Jeffries <squid3@treenet.co.nz>
Sat, 18 Jul 2009 04:06:25 +0000 (16:06 +1200)
Bug 2080: wbinfo_group.pl - false positive under certain conditions

helpers/external_acl/wbinfo_group/wbinfo_group.pl

index d5fd00732b3857b00616d9bc09ac474d935bdf9b..06e970a7599e964cfc10a9e526784f6fbe563f35 100755 (executable)
@@ -50,6 +50,8 @@ sub check {
         $groupGID = `wbinfo -Y "$groupSID"`;
         chop $groupGID;
         &debug( "User:  -$user-\nGroup: -$group-\nSID:   -$groupSID-\nGID:   -$groupGID-");
+        return 'ERR' if($groupGID eq ""); # Verify if groupGID variable is empty.
+        return 'ERR' if(`wbinfo -r \Q$user\E` eq ""); # Verify if "wbinfo -r" command returns no value.
         return 'OK' if(`wbinfo -r \Q$user\E` =~ /^$groupGID$/m);
         return 'ERR';
 }