svn commit: samba r12915 - branches/SAMBA_3_0/source/rpc_server trunk/source/rpc_server

jerry at samba.org jerry at samba.org
Fri Jan 13 20:27:00 GMT 2006


Author: jerry
Date: 2006-01-13 20:26:59 +0000 (Fri, 13 Jan 2006)
New Revision: 12915

WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=12915

Log:
protect against changing the SCM security descriptor
Modified:
   branches/SAMBA_3_0/source/rpc_server/srv_svcctl_nt.c
   trunk/source/rpc_server/srv_svcctl_nt.c


Changeset:
Modified: branches/SAMBA_3_0/source/rpc_server/srv_svcctl_nt.c
===================================================================
--- branches/SAMBA_3_0/source/rpc_server/srv_svcctl_nt.c	2006-01-13 20:24:50 UTC (rev 12914)
+++ branches/SAMBA_3_0/source/rpc_server/srv_svcctl_nt.c	2006-01-13 20:26:59 UTC (rev 12915)
@@ -828,6 +828,11 @@
 	if ( !info || !(info->type & (SVC_HANDLE_IS_SERVICE|SVC_HANDLE_IS_SCM))  )
 		return WERR_BADFID;
 
+	/* can't set the security de4scriptor on the ServiceControlManager */
+
+	if ( info->type == SVC_HANDLE_IS_SCM )
+		return WERR_ACCESS_DENIED;	
+
 	/* check the access on the open handle */
 	
 	switch ( q_u->security_flags ) {

Modified: trunk/source/rpc_server/srv_svcctl_nt.c
===================================================================
--- trunk/source/rpc_server/srv_svcctl_nt.c	2006-01-13 20:24:50 UTC (rev 12914)
+++ trunk/source/rpc_server/srv_svcctl_nt.c	2006-01-13 20:26:59 UTC (rev 12915)
@@ -828,6 +828,11 @@
 	if ( !info || !(info->type & (SVC_HANDLE_IS_SERVICE|SVC_HANDLE_IS_SCM))  )
 		return WERR_BADFID;
 
+	/* can't set the security de4scriptor on the ServiceControlManager */
+
+	if ( info->type == SVC_HANDLE_IS_SCM )
+		return WERR_ACCESS_DENIED;	
+
 	/* check the access on the open handle */
 	
 	switch ( q_u->security_flags ) {



More information about the samba-cvs mailing list