s3-secrets: only include secrets.h when needed.
[nivanova/samba-autobuild/.git] / source3 / utils / net.c
index 85c3c7dcedd8ab8fe4daaf6b13ed6242eaf27ca3..1c342858ee3f2e00c7c530a215b7d7e6955648d5 100644 (file)
@@ -42,6 +42,7 @@
 
 #include "includes.h"
 #include "utils/net.h"
+#include "secrets.h"
 
 extern bool AllowDebugChange;
 
@@ -231,7 +232,7 @@ static int net_getauthuser(struct net_context *c, int argc, const char **argv)
  */
 static int net_getlocalsid(struct net_context *c, int argc, const char **argv)
 {
-        DOM_SID sid;
+        struct dom_sid sid;
        const char *name;
        fstring sid_str;
 
@@ -271,7 +272,7 @@ static int net_getlocalsid(struct net_context *c, int argc, const char **argv)
 
 static int net_setlocalsid(struct net_context *c, int argc, const char **argv)
 {
-       DOM_SID sid;
+       struct dom_sid sid;
 
        if ( (argc != 1)
             || (strncmp(argv[0], "S-1-5-21-", strlen("S-1-5-21-")) != 0)
@@ -292,7 +293,7 @@ static int net_setlocalsid(struct net_context *c, int argc, const char **argv)
 
 static int net_setdomainsid(struct net_context *c, int argc, const char **argv)
 {
-       DOM_SID sid;
+       struct dom_sid sid;
 
        if ( (argc != 1)
             || (strncmp(argv[0], "S-1-5-21-", strlen("S-1-5-21-")) != 0)
@@ -313,7 +314,7 @@ static int net_setdomainsid(struct net_context *c, int argc, const char **argv)
 
 static int net_getdomainsid(struct net_context *c, int argc, const char **argv)
 {
-       DOM_SID domain_sid;
+       struct dom_sid domain_sid;
        fstring sid_str;
 
        if (argc > 0) {
@@ -612,6 +613,13 @@ static struct functable net_func[] = {
                N_("  Use 'net help lookup' to get more information about 'net "
                   "lookup' commands.")
        },
+       {       "g_lock",
+               net_g_lock,
+               NET_TRANSPORT_LOCAL,
+               N_("Manipulate the global lock table"),
+               N_("  Use 'net help g_lock' to get more information about "
+                  "'net g_lock' commands.")
+       },
        {       "join",
                net_join,
                NET_TRANSPORT_ADS | NET_TRANSPORT_RPC,
@@ -712,6 +720,21 @@ static struct functable net_func[] = {
                N_("  Use 'net help eventlog' to get more information about "
                   "'net eventlog' commands.")
        },
+       {       "printing",
+               net_printing,
+               NET_TRANSPORT_LOCAL,
+               N_("Process tdb printer files"),
+               N_("  Use 'net help printing' to get more information about "
+                  "'net printing' commands.")
+       },
+
+       {       "serverid",
+               net_serverid,
+               NET_TRANSPORT_LOCAL,
+               N_("Manage the serverid tdb"),
+               N_("  Use 'net help serverid' to get more information about "
+                  "'net serverid' commands.")
+       },
 
 #ifdef WITH_FAKE_KASERVER
        {       "afs",
@@ -890,7 +913,7 @@ static struct functable net_func[] = {
        load_interfaces();
 
        /* this makes sure that when we do things like call scripts,
-          that it won't assert becouse we are not root */
+          that it won't assert because we are not root */
        sec_init();
 
        if (c->opt_machine_pass) {