svn commit: samba r15119 - branches/SAMBA_3_0/source/smbd
trunk/source/smbd
vlendec at samba.org
vlendec at samba.org
Tue Apr 18 09:02:58 GMT 2006
Author: vlendec
Date: 2006-04-18 09:02:58 +0000 (Tue, 18 Apr 2006)
New Revision: 15119
WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=15119
Log:
Initialize our global sam sid first, quite a lot of the other initialization
routines further down depend on it.
Fix bug 3696.
Volker
Modified:
branches/SAMBA_3_0/source/smbd/server.c
trunk/source/smbd/server.c
Changeset:
Modified: branches/SAMBA_3_0/source/smbd/server.c
===================================================================
--- branches/SAMBA_3_0/source/smbd/server.c 2006-04-18 08:33:48 UTC (rev 15118)
+++ branches/SAMBA_3_0/source/smbd/server.c 2006-04-18 09:02:58 UTC (rev 15119)
@@ -912,6 +912,28 @@
if (!message_init())
exit(1);
+ /* Initialize our global sam sid first -- quite a lot of the other
+ * initialization routines further down depend on it.
+ */
+
+ /* Initialise the password backed before the global_sam_sid
+ to ensure that we fetch from ldap before we make a domain sid up */
+
+ if(!initialize_password_db(False))
+ exit(1);
+
+ /* Fail gracefully if we can't open secrets.tdb */
+
+ if (!secrets_init()) {
+ DEBUG(0, ("ERROR: smbd can not open secrets.tdb\n"));
+ exit(1);
+ }
+
+ if(!get_global_sam_sid()) {
+ DEBUG(0,("ERROR: Samba cannot create a SAM SID.\n"));
+ exit(1);
+ }
+
if (!session_init())
exit(1);
@@ -965,17 +987,6 @@
* everything after this point is run after the fork()
*/
- /* Initialise the password backed before the global_sam_sid
- to ensure that we fetch from ldap before we make a domain sid up */
-
- if(!initialize_password_db(False))
- exit(1);
-
- if(!get_global_sam_sid()) {
- DEBUG(0,("ERROR: Samba cannot create a SAM SID.\n"));
- exit(1);
- }
-
static_init_rpc;
init_modules();
Modified: trunk/source/smbd/server.c
===================================================================
--- trunk/source/smbd/server.c 2006-04-18 08:33:48 UTC (rev 15118)
+++ trunk/source/smbd/server.c 2006-04-18 09:02:58 UTC (rev 15119)
@@ -912,6 +912,22 @@
if (!message_init())
exit(1);
+ /* Initialise the password backed before the global_sam_sid
+ to ensure that we fetch from ldap before we make a domain sid up */
+
+ if(!initialize_password_db(False))
+ exit(1);
+
+ if (!secrets_init()) {
+ DEBUG(0, ("ERROR: smbd can not open secrets.tdb\n"));
+ exit(1);
+ }
+
+ if(!get_global_sam_sid()) {
+ DEBUG(0,("ERROR: Samba cannot create a SAM SID.\n"));
+ exit(1);
+ }
+
if (!session_init())
exit(1);
@@ -965,17 +981,6 @@
* everything after this point is run after the fork()
*/
- /* Initialise the password backed before the global_sam_sid
- to ensure that we fetch from ldap before we make a domain sid up */
-
- if(!initialize_password_db(False))
- exit(1);
-
- if(!get_global_sam_sid()) {
- DEBUG(0,("ERROR: Samba cannot create a SAM SID.\n"));
- exit(1);
- }
-
static_init_rpc;
init_modules();
More information about the samba-cvs
mailing list