]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
r18182: only grant privs to Administrators if privileges are enabled to avoid bopgus...
authorGerald Carter <jerry@samba.org>
Wed, 6 Sep 2006 15:17:25 +0000 (15:17 +0000)
committerGerald (Jerry) Carter <jerry@samba.org>
Wed, 10 Oct 2007 16:43:30 +0000 (11:43 -0500)
(This used to be commit 7d5356fd5db6ece2504c9c140d1f454056be7164)

source3/lib/account_pol.c

index de5a37aea91b562ea82efe29e36db6ea1c71e08f..e6ef8dbbe4b3be3b93bed9d06aae54fc6fd118f2 100644 (file)
@@ -303,8 +303,11 @@ BOOL init_account_policy(void)
 
        /* BUILTIN\Administrators get everything -- *always* */
 
-       if ( !grant_all_privileges( &global_sid_Builtin_Administrators ) ) {
-               DEBUG(0,("init_account_policy: Failed to grant privileges to BUILTIN\\Administrators!\n"));
+       if ( lp_enable_privileges() ) {
+               if ( !grant_all_privileges( &global_sid_Builtin_Administrators ) ) {
+                       DEBUG(1,("init_account_policy: Failed to grant privileges "
+                               "to BUILTIN\\Administrators!\n"));
+               }
        }
 
        return True;