]> andersk Git - moira.git/blobdiff - server/queries2.c
Missing close quote.
[moira.git] / server / queries2.c
index 4c7d7e9712a58b3d10acab4b7d15bfb7070df4a4..6c25f36aaab898b3bc12841abb46fbe773114d9e 100644 (file)
@@ -43,7 +43,7 @@ static struct valobj VOfilesys0[] = {
 };
 
 static struct valobj VOcon0[] = {
-       {V_ID, 0, CONTAINERS_TABLE, "name", "cnt_id", MR_CONTAINER},
+  {V_ID, 0, CONTAINERS_TABLE, "name", "cnt_id", MR_CONTAINER},
 };
 
 static struct valobj VOnum0[] = {
@@ -86,10 +86,26 @@ static char *gual2_fields[] = {
   "modtime", "modby", "modwith",
 };
 
+static char *gual3_fields[] = {
+  "login",
+  "login", "unix_uid", "shell", "winconsoleshell", "last", "first", "middle",
+  "status", "clearid", "class", "comments", "signature", "secure", "modtime",
+  "modby", "modwith", "created", "creator",
+};
+
+static char *gual11_fields[] = {
+  "login",
+  "login", "unix_uid", "shell", "winconsoleshell", "last", "first", "middle",
+  "status", "clearid", "class", "comments", "signature", "secure",
+  "winhomedir", "winprofiledir", "modtime", "modby", "modwith", "created",
+  "creator",
+};
+
 static char *gual_fields[] = {
   "login",
-  "login", "unix_uid", "shell", "winconsoleshell", "last", "first", "middle", 
+  "login", "unix_uid", "shell", "winconsoleshell", "last", "first", "middle",
   "status", "clearid", "class", "comments", "signature", "secure",
+  "winhomedir", "winprofiledir", "sponsor_type", "sponsor_name", "expiration",
   "modtime", "modby", "modwith", "created", "creator",
 };
 
@@ -139,13 +155,29 @@ static char *guau2_fields[] = {
   "modtime", "modby", "modwith",
 };
 
-static char *guau_fields[] = {
+static char *guau3_fields[] = {
   "unix_uid",
   "login", "unix_uid", "shell", "winconsoleshell", "last", "first", "middle", 
   "status", "clearid", "class", "comments", "signature", "secure",
   "modtime", "modby", "modwith", "created", "creator",
 };
 
+static char *guau11_fields[] = {
+  "unix_uid",
+  "login", "unix_uid", "shell", "winconsoleshell", "last", "first", "middle",
+  "status", "clearid", "class", "comments", "signature", "secure", 
+  "winhomedir", "winprofiledir", "modtime", "modby", "modwith", "created",
+  "creator",
+};
+
+static char *guau_fields[] = {
+  "unix_uid",
+  "login", "unix_uid", "shell", "winconsoleshell", "last", "first", "middle",
+  "status", "clearid", "class", "comments", "signature", "secure", 
+  "winhomedir", "winprofiledir", "sponsor_type", "sponsor_name", "expiration",
+  "modtime", "modby", "modwith", "created", "creator",
+};
+
 static char *guan2_fields[] = {
   "first", "last",
   "login", "unix_uid", "shell", "last", "first", "middle", "status",
@@ -153,13 +185,29 @@ static char *guan2_fields[] = {
   "modtime", "modby", "modwith",
 };
 
-static char *guan_fields[] = {
+static char *guan3_fields[] = {
   "first", "last",
   "login", "unix_uid", "shell", "winconsoleshell", "last", "first", "middle", 
   "status", "clearid", "class", "comments", "signature", "secure",
   "modtime", "modby", "modwith", "created", "creator",
 };
 
+static char *guan11_fields[] = {
+  "first", "last",
+  "login", "unix_uid", "shell", "winconsoleshell", "last", "first", "middle",
+  "status", "clearid", "class", "comments", "signature", "secure",
+  "winhomedir", "winprofiledir", "modtime", "modby", "modwith", "created",
+  "creator",
+};
+
+static char *guan_fields[] = {
+  "first", "last",
+  "login", "unix_uid", "shell", "winconsoleshell", "last", "first", "middle",
+  "status", "clearid", "class", "comments", "signature", "secure",
+  "winhomedir", "winprofiledir", "sponsor_type", "sponsor_name", "expiration",
+  "modtime", "modby", "modwith", "created", "creator",
+};
+
 static struct validate guan2_validate =
 {
   0,
@@ -193,13 +241,29 @@ static char *guac2_fields[] = {
   "modtime", "modby", "modwith",
 };
 
-static char *guac_fields[] = {
+static char *guac3_fields[] = {
   "class",
   "login", "unix_uid", "shell", "winconsoleshell", "last", "first", "middle", 
   "status", "clearid", "class", "comments", "signature", "secure",
   "modtime", "modby", "modwith", "created", "creator",
 };
 
+static char *guac11_fields[] = {
+  "class",
+  "login", "unix_uid", "shell", "winconsoleshell", "last", "first", "middle",
+  "status", "clearid", "class", "comments", "signature", "secure",
+  "winhomedir", "winprofiledir", "modtime", "modby", "modwith", "created",
+  "creator",
+};
+
+static char *guac_fields[] = {
+  "class",
+  "login", "unix_uid", "shell", "winconsoleshell", "last", "first", "middle",
+  "status", "clearid", "class", "comments", "signature", "secure",
+  "winhomedir", "winprofiledir", "sponsor_type", "sponsor_name", "expiration",
+  "modtime", "modby", "modwith", "created", "creator",
+};
+
 static char *guam2_fields[] = {
   "clearid",
   "login", "unix_uid", "shell", "last", "first", "middle", "status",
@@ -207,13 +271,51 @@ static char *guam2_fields[] = {
   "modtime", "modby", "modwith",
 };
 
-static char *guam_fields[] = {
+static char *guam3_fields[] = {
   "clearid",
   "login", "unix_uid", "shell", "winconsoleshell", "last", "first", "middle", 
   "status", "clearid", "class", "comments", "signature", "secure",
   "modtime", "modby", "modwith", "created", "creator", 
 };
 
+static char *guam11_fields[] = {
+  "clearid",
+  "login", "unix_uid", "shell", "winconsoleshell", "last", "first", "middle",
+  "status", "clearid", "class", "comments", "signature", "secure",
+  "winhomedir", "winprofiledir", "modtime", "modby", "modwith", "created",
+  "creator", 
+};
+
+static char *guam_fields[] = {
+  "clearid",
+  "login", "unix_uid", "shell", "winconsoleshell", "last", "first", "middle",
+  "status", "clearid", "class", "comments", "signature", "secure",
+  "winhomedir", "winprofiledir", "sponsor_type", "sponsor_name", "expiration",
+  "modtime", "modby", "modwith", "created", "creator", 
+};
+
+static char *guas_fields[] = {
+  "sponsor_type", "sponsor_name",
+  "login",
+};
+
+static struct valobj guas_valobj[] = {
+  {V_TYPE, 0, 0, "gaus", 0, MR_TYPE},
+  {V_TYPEDATA, 1, 0, 0, 0, MR_NO_MATCH},
+};
+
+static struct validate guas_validate = {
+  guas_valobj,
+  2,
+  0,
+  0,
+  0,
+  0,
+  access_member,
+  0,
+  get_user_account_by_sponsor,
+};
+
 static char *gubu2_fields[] = {
   "unix_uid",
   "login", "unix_uid", "shell", "last", "first", "middle", "status",
@@ -323,11 +425,23 @@ static char *auac2_fields[] = {
   "clearid", "class", "comments", "signature", "secure",
 };
 
-static char *auac_fields[] = {
+static char *auac3_fields[] = {
   "login", "unix_uid", "shell", "winconsoleshell", "last", "first", 
   "middle", "status", "clearid", "class", "comments", "signature", "secure",
 };
 
+static char *auac11_fields[] = {
+  "login", "unix_uid", "shell", "winconsoleshell", "last", "first", "middle",
+  "status", "clearid", "class", "comments", "signature", "secure",
+  "winhomedir", "winprofiledir",
+};
+
+static char *auac_fields[] = {
+  "login", "unix_uid", "shell", "winconsoleshell", "last", "first", "middle",
+  "status", "clearid", "class", "comments", "signature", "secure",
+  "winhomedir", "winprofiledir", "sponsor_type", "sponsor_name", "expiration",
+};
+
 static struct valobj auac2_valobj[] = {
   {V_CHAR, 0, USERS_TABLE, "login"},
   {V_NUM, 1},
@@ -342,6 +456,38 @@ static struct valobj auac2_valobj[] = {
   {V_NUM, 11},
 };
 
+static struct valobj auac3_valobj[] = {
+  {V_CHAR, 0, USERS_TABLE, "login"},
+  {V_NUM, 1},
+  {V_CHAR, 2, USERS_TABLE, "shell"},
+  {V_CHAR, 3, USERS_TABLE, "winconsoleshell"},
+  {V_CHAR, 4, USERS_TABLE, "last"},
+  {V_CHAR, 5, USERS_TABLE, "first"},
+  {V_CHAR, 6, USERS_TABLE, "middle"},
+  {V_NUM, 7},
+  {V_CHAR, 8, USERS_TABLE, "clearid"},
+  {V_TYPE, 9, 0, "class", 0, MR_BAD_CLASS},
+  {V_ID, 10, STRINGS_TABLE, "string", "string_id", MR_NO_MATCH},
+  {V_NUM, 12},
+};
+
+static struct valobj auac11_valobj[] = {
+  {V_CHAR, 0, USERS_TABLE, "login"},
+  {V_NUM, 1},
+  {V_CHAR, 2, USERS_TABLE, "shell"},
+  {V_CHAR, 3, USERS_TABLE, "winconsoleshell"},
+  {V_CHAR, 4, USERS_TABLE, "last"},
+  {V_CHAR, 5, USERS_TABLE, "first"},
+  {V_CHAR, 6, USERS_TABLE, "middle"},
+  {V_NUM, 7},
+  {V_CHAR, 8, USERS_TABLE, "clearid"},
+  {V_TYPE, 9, 0, "class", 0, MR_BAD_CLASS},
+  {V_ID, 10, STRINGS_TABLE, "string", "string_id", MR_NO_MATCH},
+  {V_NUM, 12},
+  {V_LEN, 13, USERS_TABLE, "winhomedir"},
+  {V_LEN, 14, USERS_TABLE, "winprofiledir"},
+};
+
 static struct valobj auac_valobj[] = {
   {V_CHAR, 0, USERS_TABLE, "login"},
   {V_NUM, 1},
@@ -355,6 +501,11 @@ static struct valobj auac_valobj[] = {
   {V_TYPE, 9, 0, "class", 0, MR_BAD_CLASS},
   {V_ID, 10, STRINGS_TABLE, "string", "string_id", MR_NO_MATCH},
   {V_NUM, 12},
+  {V_LEN, 13, USERS_TABLE, "winhomedir"},
+  {V_LEN, 14, USERS_TABLE, "winprofiledir"},
+  {V_TYPE, 15, 0, "ace_type", 0, MR_ACE},
+  {V_TYPEDATA, 16, 0, 0, "list_id", MR_ACE},
+  {V_CHAR, 17, USERS_TABLE, "expiration"},
 };
 
 static struct validate auac2_validate = {
@@ -369,9 +520,33 @@ static struct validate auac2_validate = {
   followup_ausr,
 };
 
+static struct validate auac3_validate = {
+  auac3_valobj,
+  12,
+  "login",
+  "login = '%s'",
+  1,
+  "users_id",
+  0,
+  setup_ausr,
+  followup_ausr,
+};
+
+static struct validate auac11_validate = {
+  auac11_valobj,
+  14,
+  "login",
+  "login = '%s'",
+  1,
+  "users_id",
+  0,
+  setup_ausr,
+  followup_ausr,
+};
+
 static struct validate auac_validate = {
   auac_valobj,
-  12,
+  17,
   "login",
   "login = '%s'",
   1,
@@ -393,9 +568,33 @@ static struct validate ausr2_validate = {
   followup_ausr,
 };
 
+static struct validate ausr3_validate = {
+  auac3_valobj,
+  10,
+  "login",
+  "login = '%s'",
+  1,
+  "users_id",
+  0,
+  setup_ausr,
+  followup_ausr,
+};
+
+static struct validate ausr11_validate = {
+  auac11_valobj,
+  12,
+  "login",
+  "login = '%s'",
+  1,
+  "users_id",
+  0,
+  setup_ausr,
+  followup_ausr,
+};
+
 static struct validate ausr_validate = {
   auac_valobj,
-  10,
+  15,
   "login",
   "login = '%s'",
   1,
@@ -432,12 +631,26 @@ static char *uuac2_fields[] = {
   "clearid", "class", "comments", "signature", "secure",
 };
 
-static char *uuac_fields[] = {
+static char *uuac3_fields[] = {
   "login",
   "newlogin", "unix_uid", "shell", "winconsoleshell", "last", "first", 
   "middle", "status", "clearid", "class", "comments", "signature", "secure",
 };
 
+static char *uuac11_fields[] = {
+  "login",
+  "newlogin", "unix_uid", "shell", "winconsoleshell", "last", "first",
+  "middle", "status", "clearid", "class", "comments", "signature", "secure",
+  "winhomedir", "winprofiledir",
+};
+
+static char *uuac_fields[] = {
+  "login",
+  "newlogin", "unix_uid", "shell", "winconsoleshell", "last", "first",
+  "middle", "status", "clearid", "class", "comments", "signature", "secure",
+  "winhomedir", "winprofiledir", "sponsor_type", "sponsor_name", "expiration",
+};
+
 static struct valobj uuac2_valobj[] = {
   {V_ID, 0, USERS_TABLE, "login", "users_id", MR_USER},
   {V_RENAME, 1, USERS_TABLE, "login", "users_id", MR_NOT_UNIQUE},
@@ -453,6 +666,40 @@ static struct valobj uuac2_valobj[] = {
   {V_NUM, 12},
 };
   
+static struct valobj uuac3_valobj[] = {
+  {V_ID, 0, USERS_TABLE, "login", "users_id", MR_USER},
+  {V_RENAME, 1, USERS_TABLE, "login", "users_id", MR_NOT_UNIQUE},
+  {V_NUM, 2},
+  {V_CHAR, 3, USERS_TABLE, "shell"},
+  {V_CHAR, 4, USERS_TABLE, "winconsoleshell"},
+  {V_CHAR, 5, USERS_TABLE, "first"},
+  {V_CHAR, 6, USERS_TABLE, "last"},
+  {V_CHAR, 7, USERS_TABLE, "middle"},
+  {V_NUM, 8},
+  {V_CHAR, 9, USERS_TABLE, "clearid"},
+  {V_TYPE, 10, 0, "class", 0, MR_BAD_CLASS},
+  {V_ID, 11, STRINGS_TABLE, "string", "string_id", MR_NO_MATCH},
+  {V_NUM, 13},
+};
+
+static struct valobj uuac11_valobj[] = {
+  {V_ID, 0, USERS_TABLE, "login", "users_id", MR_USER},
+  {V_RENAME, 1, USERS_TABLE, "login", "users_id", MR_NOT_UNIQUE},
+  {V_NUM, 2},
+  {V_CHAR, 3, USERS_TABLE, "shell"},
+  {V_CHAR, 4, USERS_TABLE, "winconsoleshell"},
+  {V_CHAR, 5, USERS_TABLE, "first"},
+  {V_CHAR, 6, USERS_TABLE, "last"},
+  {V_CHAR, 7, USERS_TABLE, "middle"},
+  {V_NUM, 8},
+  {V_CHAR, 9, USERS_TABLE, "clearid"},
+  {V_TYPE, 10, 0, "class", 0, MR_BAD_CLASS},
+  {V_ID, 11, STRINGS_TABLE, "string", "string_id", MR_NO_MATCH},
+  {V_NUM, 13},
+  {V_LEN, 14, USERS_TABLE, "winhomedir"},
+  {V_LEN, 15, USERS_TABLE, "winprofiledir"},
+};
+
 static struct valobj uuac_valobj[] = {
   {V_ID, 0, USERS_TABLE, "login", "users_id", MR_USER},
   {V_RENAME, 1, USERS_TABLE, "login", "users_id", MR_NOT_UNIQUE},
@@ -467,6 +714,11 @@ static struct valobj uuac_valobj[] = {
   {V_TYPE, 10, 0, "class", 0, MR_BAD_CLASS},
   {V_ID, 11, STRINGS_TABLE, "string", "string_id", MR_NO_MATCH},
   {V_NUM, 13},
+  {V_LEN, 14, USERS_TABLE, "winhomedir"},
+  {V_LEN, 15, USERS_TABLE, "winprofiledir"},
+  {V_TYPE, 16, 0, "ace_type", 0, MR_ACE},
+  {V_TYPEDATA, 17, 0, 0, "list_id", MR_ACE},
+  {V_CHAR, 18, USERS_TABLE, "expiration"},
 };
 
 static struct validate uuac2_validate = {
@@ -481,8 +733,8 @@ static struct validate uuac2_validate = {
   set_modtime_by_id,
 };
 
-static struct validate uuac_validate = {
-  uuac_valobj,
+static struct validate uuac3_validate = {
+  uuac3_valobj,
   13,
   0,
   0,
@@ -493,6 +745,30 @@ static struct validate uuac_validate = {
   set_modtime_by_id,
 };
 
+static struct validate uuac11_validate = {
+  uuac11_valobj,
+  15,
+  0,
+  0,
+  0,
+  "users_id",
+  access_update_user,
+  setup_ausr,
+  set_modtime_by_id,
+};
+
+static struct validate uuac_validate = {
+  uuac_valobj,
+  18,
+  0,
+  0,
+  0,
+  "users_id",
+  access_update_user,
+  setup_ausr,
+  set_modtime_by_id,
+};
+
 static struct validate uusr2_validate = {
   uuac2_valobj,
   10,
@@ -505,9 +781,33 @@ static struct validate uusr2_validate = {
   set_modtime_by_id,
 };
 
+static struct validate uusr3_validate = {
+  uuac3_valobj,
+  11,
+  0,
+  0,
+  0,
+  "users_id",
+  0,
+  setup_ausr,
+  set_modtime_by_id,
+};
+
+static struct validate uusr11_validate = {
+  uuac11_valobj,
+  13,
+  0,
+  0,
+  0,
+  "users_id",
+  0,
+  setup_ausr,
+  set_modtime_by_id,
+};
+
 static struct validate uusr_validate = {
   uuac_valobj,
-  11,
+  16,
   0,
   0,
   0,
@@ -891,8 +1191,8 @@ static struct validate ghst_validate = {
   0,
   0,
   0,
-  access_host,
   0,
+  setup_ghst,
   followup_ghst,
 };
 
@@ -1526,13 +1826,20 @@ static char *glin3_fields[] = {
   "modwith",
 };
 
-static char *glin_fields[] = {
+static char *glin4_fields[] = {
   "name",
   "name", "active", "publicflg", "hidden", "maillist", "grouplist", "gid",
   "nfsgroup", "ace_type", "ace_name", "memace_type", "memace_name", 
   "description", "modtime", "modby", "modwith",
 };
 
+static char *glin_fields[] = {
+  "name",
+  "name", "active", "publicflg", "hidden", "maillist", "grouplist", "gid",
+  "nfsgroup", "mailman", "mailman_server", "ace_type", "ace_name", 
+  "memace_type", "memace_name", "description", "modtime", "modby", "modwith",
+};
+
 static struct validate glin_validate = {
   0,
   0,
@@ -1606,13 +1913,13 @@ static struct validate alis3_validate = {
   set_modtime,
 };
 
-static char *alis_fields[] = {
+static char *alis4_fields[] = {
   "name", "active", "publicflg", "hidden", "maillist", "grouplist", "gid",
   "nfsgroup", "ace_type", "ace_name", "memace_type", "memace_name", 
   "description",
 };
 
-static struct valobj alis_valobj[] = {
+static struct valobj alis4_valobj[] = {
   {V_CHAR, 0, LIST_TABLE, "name"},
   {V_NUM, 1},
   {V_NUM, 2},
@@ -1628,9 +1935,45 @@ static struct valobj alis_valobj[] = {
   {V_LEN, 12, LIST_TABLE, "description"},
 };
 
+static struct validate alis4_validate = {
+  alis4_valobj,
+  13,
+  "name",
+  "name = '%s'",
+  1,
+  "list_id",
+  0,
+  setup_alis,
+  set_modtime,
+};
+
+static char *alis_fields[] = {
+  "name", "active", "publicflg", "hidden", "maillist", "grouplist", "gid",
+  "nfsgroup", "mailman", "mailman_server", "ace_type", "ace_name", 
+  "memace_type", "memace_name", "description",
+};
+
+static struct valobj alis_valobj[] = {
+  {V_CHAR, 0, LIST_TABLE, "name"},
+  {V_NUM, 1},
+  {V_NUM, 2},
+  {V_NUM, 3},
+  {V_NUM, 4},
+  {V_NUM, 5},
+  {V_NUM, 6},
+  {V_NUM, 7},
+  {V_NUM, 8},
+  {V_ID, 9, MACHINE_TABLE, "name", "mach_id", MR_MACHINE},
+  {V_TYPE, 10, 0, "ace_type", 0, MR_ACE},
+  {V_TYPEDATA, 11, 0, 0, "list_id", MR_ACE},
+  {V_TYPE, 12, 0, "ace_type", 0, MR_ACE},
+  {V_TYPEDATA, 13, 0, 0, "list_id", MR_ACE},
+  {V_LEN, 14, LIST_TABLE, "description"},
+};
+
 static struct validate alis_validate = {
   alis_valobj,
-  13,
+  15,
   "name",
   "name = '%s'",
   1,
@@ -1705,14 +2048,14 @@ static struct validate ulis3_validate = {
   set_modtime_by_id,
 };
 
-static char *ulis_fields[] = {
+static char *ulis4_fields[] = {
   "name",
   "newname", "active", "publicflg", "hidden", "maillist", "grouplist", "gid",
   "nfsgroup", "ace_type", "ace_name", "memace_type", "memace_name",
   "description",
 };
 
-static struct valobj ulis_valobj[] = {
+static struct valobj ulis4_valobj[] = {
   {V_ID, 0, LIST_TABLE, "name", "list_id", MR_LIST},
   {V_RENAME, 1, LIST_TABLE, "name", "list_id", MR_NOT_UNIQUE},
   {V_NUM, 2},
@@ -1729,9 +2072,47 @@ static struct valobj ulis_valobj[] = {
   {V_LEN, 13, LIST_TABLE, "description"},
 };
 
+static struct validate ulis4_validate = {
+  ulis4_valobj,
+  14,
+  "name",
+  "list_id = %d",
+  1,
+  "list_id",
+  access_list,
+  setup_alis,
+  set_modtime_by_id,
+};
+
+static char *ulis_fields[] = {
+  "name",
+  "newname", "active", "publicflg", "hidden", "maillist", "grouplist", "gid",
+  "nfsgroup", "mailman", "mailman_server", "ace_type", "ace_name", 
+  "memace_type", "memace_name", "description",
+};
+
+static struct valobj ulis_valobj[] = {
+  {V_ID, 0, LIST_TABLE, "name", "list_id", MR_LIST},
+  {V_RENAME, 1, LIST_TABLE, "name", "list_id", MR_NOT_UNIQUE},
+  {V_NUM, 2},
+  {V_NUM, 3},
+  {V_NUM, 4},
+  {V_NUM, 5},
+  {V_NUM, 6},
+  {V_NUM, 7},
+  {V_NUM, 8},
+  {V_NUM, 9},
+  {V_ID, 10, MACHINE_TABLE, "name", "mach_id", MR_MACHINE},
+  {V_TYPE, 11, 0, "ace_type", 0, MR_ACE},
+  {V_TYPEDATA, 12, 0, 0, "list_id", MR_ACE},
+  {V_TYPE, 13, 0, "ace_type", 0, MR_ACE},
+  {V_TYPEDATA, 14, 0, 0, "list_id", MR_ACE},
+  {V_LEN, 15, LIST_TABLE, "description"},
+};
+
 static struct validate ulis_validate = {
   ulis_valobj,
-  14,
+  16,
   "name",
   "list_id = %d",
   1,
@@ -2240,7 +2621,7 @@ static struct validate gfsl_validate = {
   0,
   0,
   0,
-  access_filesys,
+  0,
   0,
   followup_fix_modby,
 };
@@ -2547,7 +2928,7 @@ static struct validate gqbf_validate = {
   0,
   0,
   0,
-  access_filesys,
+  0,
   0,
   followup_gqot,
 };
@@ -2612,7 +2993,7 @@ static struct validate gnfq_validate = {
   0,
   0,
   0,
-  access_filesys,
+  0,
   0,
   followup_gqot,
 };
@@ -3269,81 +3650,7 @@ static struct validate _sdl_validate =
   _sdl_followup,
 };
 
-static char *gusl_fields[] = {
-  "login", "domain_sid", 
-  "login", "sid", "created",
-};
-
-static struct validate gusl_validate =
-{
-  VOuser0,
-  1,
-  NULL,
-  NULL,
-  0,
-  0,
-  0,
-  0,
-  0,
-};
-
-static char *glsn_fields[] = {
-  "name", "domain_sid",
-  "name", "sid", "created",
-};
-
-static struct validate glsn_validate = 
-{
-  VOlist0,
-  1,
-  NULL,
-  NULL,
-  0,
-  0,
-  0,
-  0,
-  0,
-};
-
-static char *ausl_fields[] = {
-  "login", "sid",
-};
-
-static struct validate ausl_validate =
-{
-  VOuser0,
-  1,
-  "sid",
-  "users_id = %d AND sid = '%s'",
-  2,
-  0,
-  0,
-  0,
-  0,
-};
-
-static char *alsn_fields[] = {
-  "name", "sid",
-};
-
-static struct validate alsn_validate =
-{
-  VOlist0,
-  1,
-  "sid",
-  "list_id = %d AND sid = '%s'",
-  2,
-  0,
-  0,
-  0,
-  0,
-};
-
-static char *gdds_fields[] = {
-  "sid",
-};
-
-static char *gcon_fields[] = {
+static char *gcon7_fields[] = {
   "name",
   "name", "description", "location", "contact",
   "ace_type", "ace_name", "memace_type", "memace_name", "modtime", "modby", "modwith",
@@ -3361,12 +3668,18 @@ static struct validate gcon_validate = {
   followup_gcon,
 };
 
-static char *acon_fields[] = {
+static char *gcon_fields[] = {
+  "name",
+  "name", "publicflg", "description", "location", "contact",
+  "ace_type", "ace_name", "memace_type", "memace_name", "modtime", "modby", "modwith",
+};
+
+static char *acon7_fields[] = {
   "name", "description", "location", "contact",
   "ace_type", "ace_name", "memace_type", "memace_name",
 };
 
-static struct valobj acon_valobj[] = {
+static struct valobj acon7_valobj[] = {
   {V_CHAR, 0, CONTAINERS_TABLE, "name"},
   {V_LEN, 1, CONTAINERS_TABLE, "description"},
   {V_CHAR, 2, CONTAINERS_TABLE, "location"},
@@ -3377,26 +3690,56 @@ static struct valobj acon_valobj[] = {
   {V_TYPEDATA, 7, 0, 0, 0, MR_ACE},
 };
 
+static struct validate acon7_validate =
+{
+  acon7_valobj,
+  8,
+  "name",
+  "name = '%s'",
+  1,
+  "cnt_id",
+  0,
+  setup_acon,
+  set_modtime,
+};
+
+static char *acon_fields[] = {
+  "name", "publicflg", "description", "location", "contact",
+  "ace_type", "ace_name", "memace_type", "memace_name",
+};
+
+static struct valobj acon_valobj[] = {
+  {V_CHAR, 0, CONTAINERS_TABLE, "name"},
+  {V_NUM, 1},
+  {V_LEN, 2, CONTAINERS_TABLE, "description"},
+  {V_CHAR, 3, CONTAINERS_TABLE, "location"},
+  {V_CHAR, 4, CONTAINERS_TABLE, "contact"},
+  {V_TYPE, 5, 0, "ace_type", 0, MR_ACE},
+  {V_TYPEDATA, 6, 0, 0, 0, MR_ACE},
+  {V_TYPE, 7, 0, "ace_type", 0, MR_ACE},
+  {V_TYPEDATA, 8, 0, 0, 0, MR_ACE},
+};
+
 static struct validate acon_validate =
 {
   acon_valobj,
-  8,
+  9,
   "name",
   "name = '%s'",
   1,
   "cnt_id",
   0,
-  prefetch_value,
+  setup_acon,
   set_modtime,
 };
 
-static char *ucon_fields[] = {
+static char *ucon7_fields[] = {
   "name",
   "newname", "description", "location", "contact",
   "ace_type", "ace_name", "memace_type", "memace_name",
 };
 
-static struct valobj ucon_valobj[] = {
+static struct valobj ucon7_valobj[] = {
   {V_ID, 0, CONTAINERS_TABLE, "name", "cnt_id", MR_CONTAINER},
   {V_RENAME, 1, CONTAINERS_TABLE, "name", "cnt_id", MR_NOT_UNIQUE},
   {V_LEN, 2, CONTAINERS_TABLE, "description"},
@@ -3408,10 +3751,42 @@ static struct valobj ucon_valobj[] = {
   {V_TYPEDATA, 8, 0, 0, 0, MR_ACE},
 };
 
+static struct validate ucon7_validate =
+{
+  ucon7_valobj,
+  9,
+  0,
+  0,
+  0,
+  0,
+  access_container,
+  0,
+  update_container,
+};
+
+static char *ucon_fields[] = {
+  "name",
+  "newname", "publicflg", "description", "location", "contact",
+  "ace_type", "ace_name", "memace_type", "memace_name",
+};
+
+static struct valobj ucon_valobj[] = {
+  {V_ID, 0, CONTAINERS_TABLE, "name", "cnt_id", MR_CONTAINER},
+  {V_RENAME, 1, CONTAINERS_TABLE, "name", "cnt_id", MR_NOT_UNIQUE},
+  {V_NUM, 2},
+  {V_LEN, 3, CONTAINERS_TABLE, "description"},
+  {V_CHAR, 4, CONTAINERS_TABLE, "location"},
+  {V_CHAR, 5, CONTAINERS_TABLE, "contact"},
+  {V_TYPE, 6, 0, "ace_type", 0, MR_ACE},
+  {V_TYPEDATA, 7, 0, 0, 0, MR_ACE},
+  {V_TYPE, 8, 0, "ace_type", 0, MR_ACE},
+  {V_TYPEDATA, 9, 0, 0, 0, MR_ACE},
+};
+
 static struct validate ucon_validate =
 {
   ucon_valobj,
-  9,
+  10,
   0,
   0,
   0,
@@ -3522,6 +3897,50 @@ static char *gtlc_fields[] = {
   "name",
 };
 
+static char *scli_fields[] = {
+  "containername",
+  "listname",
+};
+
+static struct valobj scli_valobj[] = {
+  {V_ID, 0, CONTAINERS_TABLE, "name", "cnt_id", MR_CONTAINER},
+  {V_ID, 1, LIST_TABLE, "name", "list_id", MR_LIST},
+};
+
+static struct validate scli_validate = {
+  scli_valobj,
+  2,
+  0,
+  0,
+  0,
+  0,
+  0,
+  setup_scli,
+  set_container_list,
+};
+
+static char *gcli_fields[] = {
+  "containername",
+  "containername", "listname",
+};
+
+static struct validate glic_validate = 
+{
+  VOlist0,
+  1,
+  NULL,
+  NULL,
+  0,
+  0,
+  0,
+  0,
+  0,
+};
+
+static char *glic_fields[] = {
+  "listname",
+  "containername", "listname",
+};
 
 /* Generalized Query Definitions */
 
@@ -3628,7 +4047,7 @@ struct query Queries[] = {
     "u",
     USERS_TABLE,
     "u.login, u.unix_uid, u.shell, u.winconsoleshell, u.last, u.first, u.middle, u.status, u.clearid, u.type, str.string, CHR(0), u.secure, TO_CHAR(u.modtime, 'DD-mon-YYYY HH24:MI:SS'), u.modby, u.modwith, TO_CHAR(u.created, 'DD-mon-YYYY HH24:MI:SS'), u.creator FROM users u, strings str",
-    gual_fields,
+    gual3_fields,
     18,
     "u.login LIKE '%s' AND u.users_id != 0 AND u.comments = str.string_id",
     1,
@@ -3636,6 +4055,40 @@ struct query Queries[] = {
     &gubl_validate,
   },
 
+  {
+    /* Q_GUAL - GET_USER_ACCOUNT_BY_LOGIN, v11 */
+    "get_user_account_by_login",
+    "gual",
+    11,
+    RETRIEVE,
+    "u",
+    USERS_TABLE,
+    "u.login, u.unix_uid, u.shell, u.winconsoleshell, u.last, u.first, u.middle, u.status, u.clearid, u.type, str.string, CHR(0), u.secure, u.winhomedir, u.winprofiledir, TO_CHAR(u.modtime, 'DD-mon-YYYY HH24:MI:SS'), u.modby, u.modwith, TO_CHAR(u.created, 'DD-mon-YYYY HH24:MI:SS'), u.creator FROM users u, strings str",
+    gual11_fields,
+    20,
+    "u.login LIKE '%s' AND u.users_id != 0 AND u.comments = str.string_id",
+    1,
+    "u.login",
+    &gubl_validate,
+  },
+
+  {
+    /* Q_GUAL - GET_USER_ACCOUNT_BY_LOGIN, v12 */
+    "get_user_account_by_login",
+    "gual",
+    12,
+    RETRIEVE,
+    "u",
+    USERS_TABLE,
+    "u.login, u.unix_uid, u.shell, u.winconsoleshell, u.last, u.first, u.middle, u.status, u.clearid, u.type, str.string, CHR(0), u.secure, u.winhomedir, u.winprofiledir, u.sponsor_type, u.sponsor_id, u.expiration, TO_CHAR(u.modtime, 'DD-mon-YYYY HH24:MI:SS'), u.modby, u.modwith, TO_CHAR(u.created, 'DD-mon-YYYY HH24:MI:SS'), u.creator FROM users u, strings str",
+    gual_fields,
+    23,
+    "u.login LIKE '%s' AND u.users_id != 0 AND u.comments = str.string_id",
+    1,
+    "u.login",
+    &gubl_validate,
+  },
+
   {
     /* Q_GUAU - GET_USER_ACCOUNT_BY_UID, v2 */
     "get_user_account_by_uid",
@@ -3662,7 +4115,7 @@ struct query Queries[] = {
     "u",
     USERS_TABLE,
     "u.login, u.unix_uid, u.shell, u.winconsoleshell, u.last, u.first, u.middle, u.status, u.clearid, u.type, str.string, CHR(0), u.secure, TO_CHAR(u.modtime, 'DD-mon-YYYY HH24:MI:SS'), u.modby, u.modwith, TO_CHAR(u.created, 'DD-mon-YYYY HH24:MI:SS'), u.creator FROM users u, strings str",
-    guau_fields,
+    guau3_fields,
     18,
     "u.unix_uid = %s AND u.users_id != 0 AND u.comments = str.string_id",
     1,
@@ -3670,6 +4123,40 @@ struct query Queries[] = {
     &gubu_validate,
   },
 
+  {
+    /* Q_GUAU - GET_USER_ACCOUNT_BY_UID, v11 */
+    "get_user_account_by_uid",
+    "guau",
+    11,
+    RETRIEVE,
+    "u",
+    USERS_TABLE,
+    "u.login, u.unix_uid, u.shell, u.winconsoleshell, u.last, u.first, u.middle, u.status, u.clearid, u.type, str.string, CHR(0), u.secure, u.winhomedir, u.winprofiledir, TO_CHAR(u.modtime, 'DD-mon-YYYY HH24:MI:SS'), u.modby, u.modwith, TO_CHAR(u.created, 'DD-mon-YYYY HH24:MI:SS'), u.creator FROM users u, strings str",
+    guau3_fields,
+    20,
+    "u.unix_uid = %s AND u.users_id != 0 AND u.comments = str.string_id",
+    1,
+    "u.login",
+    &gubu_validate,
+  }, 
+
+  {
+    /* Q_GUAU - GET_USER_ACCOUNT_BY_UID, v12 */
+    "get_user_account_by_uid",
+    "guau",
+    12,
+    RETRIEVE,
+    "u",
+    USERS_TABLE,
+    "u.login, u.unix_uid, u.shell, u.winconsoleshell, u.last, u.first, u.middle, u.status, u.clearid, u.type, str.string, CHR(0), u.secure, u.winhomedir, u.winprofiledir, u.sponsor_type, u.sponsor_id, u.expiration, TO_CHAR(u.modtime, 'DD-mon-YYYY HH24:MI:SS'), u.modby, u.modwith, TO_CHAR(u.created, 'DD-mon-YYYY HH24:MI:SS'), u.creator FROM users u, strings str",
+    guau_fields,
+    23,
+    "u.unix_uid = %s AND u.users_id != 0 AND u.comments = str.string_id",
+    1,
+    "u.login",
+    &gubu_validate,
+  }, 
+
   {
     /* Q_GUAN - GET_USER_ACCOUNT_BY_NAME, v2 */
     "get_user_account_by_name",
@@ -3696,7 +4183,7 @@ struct query Queries[] = {
     "u",
     USERS_TABLE,
     "u.login, u.unix_uid, u.shell, u.winconsoleshell, u.last, u.first, u.middle, u.status, u.clearid, u.type, str.string, CHR(0), u.secure, TO_CHAR(u.modtime, 'DD-mon-YYYY HH24:MI:SS'), u.modby, u.modwith, TO_CHAR(u.created, 'DD-mon-YYYY HH24:MI:SS'), u.creator FROM users u, strings str",
-    guan_fields,
+    guan3_fields,
     18,
     "u.first LIKE '%s' AND u.last LIKE '%s' AND u.users_id != 0 and u.comments = str.string_id",
     2,
@@ -3704,6 +4191,40 @@ struct query Queries[] = {
     &guan_validate,
   },
 
+  {
+    /* Q_GUAN - GET_USER_ACCOUNT_BY_NAME, v11 */
+    "get_user_account_by_name",
+    "guan",
+    11,
+    RETRIEVE,
+    "u",
+    USERS_TABLE,
+    "u.login, u.unix_uid, u.shell, u.winconsoleshell, u.last, u.first, u.middle, u.status, u.clearid, u.type, str.string, CHR(0), u.secure, u.winhomedir, u.winprofiledir, TO_CHAR(u.modtime, 'DD-mon-YYYY HH24:MI:SS'), u.modby, u.modwith, TO_CHAR(u.created, 'DD-mon-YYYY HH24:MI:SS'), u.creator FROM users u, strings str",
+    guan11_fields,
+    20,
+    "u.first LIKE '%s' AND u.last LIKE '%s' AND u.users_id != 0 and u.comments = str.string_id",
+    2,
+    "u.login",
+    &guan_validate,
+  },
+
+  {
+    /* Q_GUAN - GET_USER_ACCOUNT_BY_NAME, v12 */
+    "get_user_account_by_name",
+    "guan",
+    12,
+    RETRIEVE,
+    "u",
+    USERS_TABLE,
+    "u.login, u.unix_uid, u.shell, u.winconsoleshell, u.last, u.first, u.middle, u.status, u.clearid, u.type, str.string, CHR(0), u.secure, u.winhomedir, u.winprofiledir, u.sponsor_type, u.sponsor_id, u.expiration, TO_CHAR(u.modtime, 'DD-mon-YYYY HH24:MI:SS'), u.modby, u.modwith, TO_CHAR(u.created, 'DD-mon-YYYY HH24:MI:SS'), u.creator FROM users u, strings str",
+    guan_fields,
+    23,
+    "u.first LIKE '%s' AND u.last LIKE '%s' AND u.users_id != 0 and u.comments = str.string_id",
+    2,
+    "u.login",
+    &guan_validate,
+  },
+
   {
     /* Q_GUAC - GET_USER_ACCOUNT_BY_CLASS, v2 */
     "get_user_account_by_class",
@@ -3730,7 +4251,7 @@ struct query Queries[] = {
     "u",
     USERS_TABLE,
     "u.login, u.unix_uid, u.shell, u.winconsoleshell, u.last, u.first, u.middle, u.status, u.clearid, u.type, str.string, CHR(0), u.secure, TO_CHAR(u.modtime, 'DD-mon-YYYY HH24:MI:SS'), u.modby, u.modwith, TO_CHAR(u.created, 'DD-mon-YYYY HH24:MI:SS'), u.creator FROM users u, strings str",
-    guac_fields,
+    guac3_fields,
     18,
     "u.type = UPPER('%s') AND u.users_id != 0 AND u.comments = str.string_id",
     1,
@@ -3738,6 +4259,40 @@ struct query Queries[] = {
     &guan_validate,
   },
 
+  {
+    /* Q_GUAC - GET_USER_ACCOUNT_BY_CLASS, v11 */
+    "get_user_account_by_class",
+    "guac",
+    11,
+    RETRIEVE,
+    "u",
+    USERS_TABLE,
+    "u.login, u.unix_uid, u.shell, u.winconsoleshell, u.last, u.first, u.middle, u.status, u.clearid, u.type, str.string, CHR(0), u.secure, u.winhomedir, u.winprofiledir, TO_CHAR(u.modtime, 'DD-mon-YYYY HH24:MI:SS'), u.modby, u.modwith, TO_CHAR(u.created, 'DD-mon-YYYY HH24:MI:SS'), u.creator FROM users u, strings str",
+    guac11_fields,
+    20,
+    "u.type = UPPER('%s') AND u.users_id != 0 AND u.comments = str.string_id",
+    1,
+    "u.login",
+    &guan_validate,
+  },
+
+  {
+    /* Q_GUAC - GET_USER_ACCOUNT_BY_CLASS, v12 */
+    "get_user_account_by_class",
+    "guac",
+    12,
+    RETRIEVE,
+    "u",
+    USERS_TABLE,
+    "u.login, u.unix_uid, u.shell, u.winconsoleshell, u.last, u.first, u.middle, u.status, u.clearid, u.type, str.string, CHR(0), u.secure, u.winhomedir, u.winprofiledir, u.sponsor_type, u.sponsor_id, u.expiration, TO_CHAR(u.modtime, 'DD-mon-YYYY HH24:MI:SS'), u.modby, u.modwith, TO_CHAR(u.created, 'DD-mon-YYYY HH24:MI:SS'), u.creator FROM users u, strings str",
+    guac_fields,
+    23,
+    "u.type = UPPER('%s') AND u.users_id != 0 AND u.comments = str.string_id",
+    1,
+    "u.login",
+    &guan_validate,
+  },
+
   {
     /* Q_GUAM - GET_USER_ACCOUNT_BY_MITID, v2 */
     "get_user_account_by_id",
@@ -3772,6 +4327,57 @@ struct query Queries[] = {
     &guan_validate,
   },
 
+  {
+    /* Q_GUAM - GET_USER_ACCOUNT_BY_MITID, v11 */
+    "get_user_account_by_id",
+    "guai",
+    11,
+    RETRIEVE,
+    "u",
+    USERS_TABLE,
+    "u.login, u.unix_uid, u.shell, u.winconsoleshell, u.last, u.first, u.middle, u.status, u.clearid, u.type, str.string, CHR(0), u.secure, u.winhomedir, u.winprofiledir, TO_CHAR(u.modtime, 'DD-mon-YYYY HH24:MI:SS'), u.modby, u.modwith, TO_CHAR(u.created, 'DD-mon-YYYY HH24:MI:SS'), u.creator FROM users u, strings str",
+    guam11_fields,
+    20,
+    "u.clearid LIKE '%s' AND u.users_id != 0 AND u.comments = str.string_id",
+    1,
+    "u.login",
+    &guan_validate,
+  },
+
+  {
+    /* Q_GUAM - GET_USER_ACCOUNT_BY_MITID, v12 */
+    "get_user_account_by_id",
+    "guai",
+    12,
+    RETRIEVE,
+    "u",
+    USERS_TABLE,
+    "u.login, u.unix_uid, u.shell, u.winconsoleshell, u.last, u.first, u.middle, u.status, u.clearid, u.type, str.string, CHR(0), u.secure, u.winhomedir, u.winprofiledir, u.sponsor_type, u.sponsor_id, u.expiration, TO_CHAR(u.modtime, 'DD-mon-YYYY HH24:MI:SS'), u.modby, u.modwith, TO_CHAR(u.created, 'DD-mon-YYYY HH24:MI:SS'), u.creator FROM users u, strings str",
+    guam_fields,
+    23,
+    "u.clearid LIKE '%s' AND u.users_id != 0 AND u.comments = str.string_id",
+    1,
+    "u.login",
+    &guan_validate,
+  },
+
+  {
+    /* Q_GUAS - GET_USER_ACCOUNT_BY_SPONSOR, v12 */
+    "get_user_account_by_sponsor",
+    "guas",
+    12,
+    RETRIEVE,
+    0,
+    0,
+    0,
+    guas_fields,
+    1,
+    0,
+    2,
+    NULL,
+    &guas_validate,
+  },
+
   {
     /* Q_GUBL - GET_USER_BY_LOGIN, v2 */
     "get_user_by_login",
@@ -3973,9 +4579,49 @@ struct query Queries[] = {
     /* We set signature to "NVL(CHR(0), '%s')", which is to say, "CHR(0)",
      * but using up one argv element.
      */
-    "INTO users (login, unix_uid, shell, winconsoleshell, last, first, middle, status, clearid, type, comments, signature, secure, users_id, created, creator) VALUES ('%s', %s, '%s', NVL('%s', CHR(0)), NVL('%s', CHR(0)), NVL('%s', CHR(0)), NVL('%s', CHR(0)), %s, NVL('%s', CHR(0)), '%s', %d, NVL(CHR(0), '%s'), %s, %s, SYSDATE, %s)",
+    "INTO users (login, unix_uid, shell, winconsoleshell, last, first, middle, status, clearid, type, comments, signature, secure, users_id, created, creator) VALUES ('%s', %s, '%s', NVL('%s', CHR(0)), NVL('%s', CHR(0)), NVL('%s', CHR(0)), NVL('%s', CHR(0)), %s, NVL('%s', CHR(0)), '%s', %d, NVL(CHR(0), '%s'), %s, %s, SYSDATE, %s)",
+    auac3_fields,
+    13,
+    NULL,
+    0,
+    NULL,
+    &auac3_validate,
+  },
+
+  {
+    /* Q_AUAC - ADD_USER_ACCOUNT, v11 */  /* uses prefetch_value() for users_id */
+    "add_user_account",
+    "auac",
+    11,
+    APPEND,
+    "u",
+    USERS_TABLE,
+    /* We set signature to "NVL(CHR(0), '%s')", which is to say, "CHR(0)",
+     * but using up one argv element.
+     */
+    "INTO users (login, unix_uid, shell, winconsoleshell, last, first, middle, status, clearid, type, comments, signature, secure, winhomedir, winprofiledir, users_id, created, creator) VALUES ('%s', %s, '%s', NVL('%s', CHR(0)), NVL('%s', CHR(0)), NVL('%s', CHR(0)), NVL('%s', CHR(0)), %s, NVL('%s', CHR(0)), '%s', %d, NVL(CHR(0), '%s'), %s, NVL('%s', CHR(0)), NVL('%s', CHR(0)), %s, SYSDATE, %s)",
+    auac11_fields,
+    15,
+    NULL,
+    0,
+    NULL,
+    &auac11_validate,
+  },
+
+  {
+    /* Q_AUAC - ADD_USER_ACCOUNT, v12 */  /* uses prefetch_value() for users_id */
+    "add_user_account",
+    "auac",
+    12,
+    APPEND,
+    "u",
+    USERS_TABLE,
+    /* We set signature to "NVL(CHR(0), '%s')", which is to say, "CHR(0)",
+     * but using up one argv element.
+     */
+    "INTO users (login, unix_uid, shell, winconsoleshell, last, first, middle, status, clearid, type, comments, signature, secure, winhomedir, winprofiledir, sponsor_type, sponsor_id, expiration, users_id, created, creator) VALUES ('%s', %s, '%s', NVL('%s', CHR(0)), NVL('%s', CHR(0)), NVL('%s', CHR(0)), NVL('%s', CHR(0)), %s, NVL('%s', CHR(0)), '%s', %d, NVL(CHR(0), '%s'), %s, NVL('%s', CHR(0)), NVL('%s', CHR(0)), '%s', %d, NVL('%s', CHR(0)), %s, SYSDATE, %s)",
     auac_fields,
-    13,
+    18,
     NULL,
     0,
     NULL,
@@ -4008,11 +4654,45 @@ struct query Queries[] = {
     "u",
     USERS_TABLE,
     "INTO users (login, unix_uid, shell, winconsoleshell, last, first, middle, status, clearid, type, comments, signature, secure, users_id, created, creator) VALUES ('%s', %s, '%s', NVL('%s', CHR(0)), NVL('%s', CHR(0)), NVL('%s', CHR(0)), %s, NVL('%s', CHR(0)), '%s', 0, CHR(0), 0, %s, SYSDATE, %s)",
-    auac_fields,
+    auac3_fields,
     10,
     0,
     0,
     NULL,
+    &ausr3_validate,
+  },
+
+  {
+    /* Q_AUSR - ADD_USER, v11 */  /* uses prefetch_value() for users_id */
+    "add_user",
+    "ausr",
+    11,
+    APPEND,
+    "u",
+    USERS_TABLE,
+    "INTO users (login, unix_uid, shell, winconsoleshell, last, first, middle, status, clearid, type, comments, signature, secure, winhomedir, winprofiledir, users_id, created, creator) VALUES ('%s', %s, '%s', NVL('%s', CHR(0)), NVL('%s', CHR(0)), NVL('%s', CHR(0)), %s, NVL('%s', CHR(0)), '%s', 0, CHR(0), 0, NVL('%s', CHR(0)), NVL('%s', CHR(0)), %s, SYSDATE, %s)",
+    auac11_fields,
+    12,
+    0,
+    0,
+    NULL,
+    &ausr11_validate,
+  },
+
+  {
+    /* Q_AUSR - ADD_USER, v12 */  /* uses prefetch_value() for users_id */
+    "add_user",
+    "ausr",
+    12,
+    APPEND,
+    "u",
+    USERS_TABLE,
+    "INTO users (login, unix_uid, shell, winconsoleshell, last, first, middle, status, clearid, type, comments, signature, secure, winhomedir, winprofiledir, sponsor_type, sponsor_id, expiration, users_id, created, creator) VALUES ('%s', %s, '%s', NVL('%s', CHR(0)), NVL('%s', CHR(0)), NVL('%s', CHR(0)), %s, NVL('%s', CHR(0)), '%s', 0, CHR(0), 0, NVL('%s', CHR(0)), NVL('%s', CHR(0)), '%s', %d, NVL('%s', CHR(0)), %s, SYSDATE, %s)",
+    auac_fields,
+    15,
+    0,
+    0,
+    NULL,
     &ausr_validate,
   },
 
@@ -4061,11 +4741,47 @@ struct query Queries[] = {
     USERS_TABLE,
     /* See comment in auac about signature. */
     "users SET login = '%s', unix_uid = %s, shell = '%s', winconsoleshell = '%s', last = NVL('%s', CHR(0)), first = NVL('%s', CHR(0)), middle = NVL('%s', CHR(0)), status = %s, clearid = NVL('%s', CHR(0)), type = '%s', comments = %d, signature = NVL(CHR(0), '%s'), secure = %s",
-    uuac_fields,
+    uuac3_fields,
     13,
     "users_id = %d",
     1,
     NULL,
+    &uuac3_validate,
+  },
+
+  {
+    /* Q_UUAC - UPDATE_USER_ACCOUNT, v11 */
+    "update_user_account",
+    "uuac",
+    11,
+    UPDATE,
+    "u",
+    USERS_TABLE,
+    /* See comment in auac about signature. */
+    "users SET login = '%s', unix_uid = %s, shell = '%s', winconsoleshell = '%s', last = NVL('%s', CHR(0)), first = NVL('%s', CHR(0)), middle = NVL('%s', CHR(0)), status = %s, clearid = NVL('%s', CHR(0)), type = '%s', comments = %d, signature = NVL(CHR(0), '%s'), secure = %s, winhomedir = NVL('%s', CHR(0)), winprofiledir = NVL('%s', CHR(0))",
+    uuac11_fields,
+    15,
+    "users_id = %d",
+    1,
+    NULL,
+    &uuac11_validate,
+  },
+
+  {
+    /* Q_UUAC - UPDATE_USER_ACCOUNT, v12 */
+    "update_user_account",
+    "uuac",
+    12,
+    UPDATE,
+    "u",
+    USERS_TABLE,
+    /* See comment in auac about signature. */
+    "users SET login = '%s', unix_uid = %s, shell = '%s', winconsoleshell = '%s', last = NVL('%s', CHR(0)), first = NVL('%s', CHR(0)), middle = NVL('%s', CHR(0)), status = %s, clearid = NVL('%s', CHR(0)), type = '%s', comments = %d, signature = NVL(CHR(0), '%s'), secure = %s, winhomedir = NVL('%s', CHR(0)), winprofiledir = NVL('%s', CHR(0)), sponsor_type = '%s', sponsor_id = %d, expiration = NVL('%s', CHR(0))",
+    uuac_fields,
+    18,
+    "users_id = %d",
+    1,
+    NULL,
     &uuac_validate,
   },
 
@@ -4095,11 +4811,45 @@ struct query Queries[] = {
     "u",
     USERS_TABLE,
     "users SET login = '%s', unix_uid = %s, shell = '%s', winconsoleshell = '%s', last = NVL('%s', CHR(0)), first = NVL('%s', CHR(0)), middle = NVL('%s', CHR(0)), status = %s, clearid = NVL('%s', CHR(0)),  type = '%s'",
-    uuac_fields,
+    uuac3_fields,
     10,
     "users_id = %d",
     1,
     NULL,
+    &uusr3_validate,
+  },
+
+  {
+    /* Q_UUSR - UPDATE_USER, v11 */
+    "update_user",
+    "uusr",
+    11,
+    UPDATE,
+    "u",
+    USERS_TABLE,
+    "users SET login = '%s', unix_uid = %s, shell = '%s', winconsoleshell = '%s', last = NVL('%s', CHR(0)), first = NVL('%s', CHR(0)), middle = NVL('%s', CHR(0)), status = %s, clearid = NVL('%s', CHR(0)),  type = '%s', winhomedir = NVL('%s', CHR(0)), winprofiledir = NVL('%s', CHR(0)) ",
+    uuac11_fields,
+    12,
+    "users_id = %d",
+    1,
+    NULL,
+    &uusr11_validate,
+  },
+
+  {
+    /* Q_UUSR - UPDATE_USER, v12 */
+    "update_user",
+    "uusr",
+    12,
+    UPDATE,
+    "u",
+    USERS_TABLE,
+    "users SET login = '%s', unix_uid = %s, shell = '%s', winconsoleshell = '%s', last = NVL('%s', CHR(0)), first = NVL('%s', CHR(0)), middle = NVL('%s', CHR(0)), status = %s, clearid = NVL('%s', CHR(0)),  type = '%s', winhomedir = NVL('%s', CHR(0)), winprofiledir = NVL('%s', CHR(0)), sponsor_type = '%s', sponsor_id = %d, expiration = NVL('%s', CHR(0)) ",
+    uuac_fields,
+    15,
+    "users_id = %d",
+    1,
+    NULL,
     &uusr_validate,
   },
 
@@ -5132,7 +5882,7 @@ struct query Queries[] = {
     "l",
     LIST_TABLE,
     "name, active, publicflg, hidden, maillist, grouplist, gid, nfsgroup, acl_type, acl_id, memacl_type, memacl_id, description, TO_CHAR(modtime, 'DD-mon-YYYY HH24:MI:SS'), modby, modwith FROM list",
-    glin_fields,
+    glin4_fields,
     16,
     "name LIKE '%s'",
     1,
@@ -5140,6 +5890,23 @@ struct query Queries[] = {
     &glin_validate,
   },
 
+  {
+    /* Q_GLIN - GET_LIST_INFO, v10 */
+    "get_list_info",
+    "glin",
+    10,
+    RETRIEVE,
+    "l",
+    LIST_TABLE,
+    "l.name, l.active, l.publicflg, l.hidden, l.maillist, l.grouplist, l.gid, l.nfsgroup, l.mailman, m.name, l.acl_type, l.acl_id, l.memacl_type, l.memacl_id, l.description, TO_CHAR(l.modtime, 'DD-mon-YYYY HH24:MI:SS'), l.modby, l.modwith FROM list l, machine m",
+    glin_fields,
+    18,
+    "l.name LIKE '%s' AND m.mach_id = l.mailman_id",
+    1,
+    "l.name",
+    &glin_validate,
+  },
+
   {
     /* Q_EXLN - EXPAND_LIST_NAMES */
     "expand_list_names",
@@ -5200,11 +5967,28 @@ struct query Queries[] = {
     "l",
     LIST_TABLE,
     "INTO list (name, active, publicflg, hidden, maillist, grouplist, gid, nfsgroup, acl_type, acl_id, memacl_type, memacl_id, description, list_id) VALUES ('%s', %s, %s, %s, %s, %s, %s, %s, '%s', %d, '%s', %d, NVL('%s', CHR(0)), %s)",
-    alis_fields,
+    alis4_fields,
     13,
     0,
     0,
     NULL,
+    &alis4_validate,
+  },
+
+  {
+    /* Q_ALIS - ADD_LIST, v10 */ /* uses prefetch_value() for list_id */
+    "add_list",
+    "alis",
+    10,
+    APPEND,
+    "l",
+    LIST_TABLE,
+    "INTO list (name, active, publicflg, hidden, maillist, grouplist, gid, nfsgroup, mailman, mailman_id, acl_type, acl_id, memacl_type, memacl_id, description, list_id) VALUES ('%s', %s, %s, %s, %s, %s, %s, %s, %s, %d, '%s', %d, '%s', %d, NVL('%s', CHR(0)), %s)",
+    alis_fields,
+    15,
+    0,
+    0,
+    NULL,
     &alis_validate,
   },
 
@@ -5251,11 +6035,28 @@ struct query Queries[] = {
     "l",
     LIST_TABLE,
     "list SET name = '%s', active = %s, publicflg = %s, hidden = %s, maillist = %s, grouplist = %s, gid = %s, nfsgroup = %s, acl_type = '%s', acl_id = %d, memacl_type = '%s', memacl_id = %d, description = NVL('%s', CHR(0))",
-    ulis_fields,
+    ulis4_fields,
     13,
     "list_id = %d",
     1,
     NULL,
+    &ulis4_validate,
+  },
+
+  {
+    /* Q_ULIS, UPDATE_LIST, v10 */
+    "update_list",
+    "ulis",
+    10,
+    UPDATE,
+    "l",
+    LIST_TABLE,
+    "list SET name = '%s', active = %s, publicflg = %s, hidden = %s, maillist = %s, grouplist = %s, gid = %s, nfsgroup = %s, mailman = %s, mailman_id = %d, acl_type = '%s', acl_id = %d, memacl_type = '%s', memacl_id = %d, description = NVL('%s', CHR(0))",
+    ulis_fields,
+    15,
+    "list_id = %d",
+    1,
+    NULL,
     &ulis_validate,
   },
 
@@ -6892,102 +7693,34 @@ struct query Queries[] = {
   },
 
   {
-    /* Q_GUSL - GET_USER_SIDS_BY_LOGIN, v4 */
-    "get_user_sids_by_login",
-    "gusl",
-    4,
-    RETRIEVE,
-    "s",
-    USERSIDS_TABLE,
-    "u.login, us.sid, TO_CHAR(us.created, 'YYYY-MM-DD HH24:MI:SS') FROM users u, usersids us",
-    gusl_fields,
-    3,
-    "us.users_id = %d AND u.users_id = us.users_id AND SUBSTR(us.sid, 1, LENGTH(us.sid)-8) = '%s'",
-    2,
-    NULL,
-    &gusl_validate,
-  },
-
-  {
-    /* Q_AUSL - ADD_USER_SID_BY_LOGIN, v4 */
-    "add_user_sid_by_login",
-    "ausl",
-    4,
-    APPEND,
-    "s",
-    USERSIDS_TABLE,
-    "INTO usersids (users_id, sid) VALUES (%d, '%s')",
-    ausl_fields,
-    2,
-    NULL,
-    0,
-    NULL,
-    &ausl_validate,
-  },
-  
-  {
-    /* Q_GLSN - GET_LIST_SIDS_BY_NAME, v4 */
-    "get_list_sids_by_name",
-    "glsn",
-    4,
-    RETRIEVE,
-    "s",
-    LISTSIDS_TABLE,
-    "l.name, ls.sid, TO_CHAR(ls.created, 'YYYY-MM-DD HH24:MI:SS') FROM list l, listsids ls",
-    glsn_fields,
-    3,
-    "ls.list_id = %d AND l.list_id = ls.list_id AND SUBSTR(ls.sid, 1, LENGTH(ls.sid)-8) = '%s'",
-    2,
-    NULL,
-    &glsn_validate,
-  },
-
-  {
-    /* Q_ALSN - ADD_LIST_SID_BY_NAME, v4 */
-    "add_list_sid_by_name",
-    "alsn",
-    4,
-    APPEND,
-    "s",
-    LISTSIDS_TABLE,
-    "INTO listsids (list_id, sid) VALUES (%d, '%s')",
-    alsn_fields,
-    2,
-    NULL,
-    0,
-    NULL,
-    &alsn_validate,
-  },
-
-  {
-    /* Q_GDDS - GET_DISTINCT_DOMAIN_SIDS, v4 */
-    "get_distinct_domain_sids",
-    "gdds",
-    4,
+    /* Q_GCON - GET_CONTAINER, v7 */
+    "get_container",
+    "gcon",
+    7,
     RETRIEVE,
-    "s",
-    USERSIDS_TABLE,
-    "DISTINCT SUBSTR(sid, 1, LENGTH(sid)-8) FROM usersids",
-    gdds_fields,
+    "c",
+    CONTAINERS_TABLE,
+    "name, description, location, contact, acl_type, acl_id, memacl_type, memacl_id, TO_CHAR(modtime, 'DD-mon-YYYY HH24:MI:SS'), modby, modwith FROM containers",
+    gcon7_fields,
+    11,
+    "LOWER(name) LIKE LOWER('%s') AND cnt_id != 0",
     1,
     NULL,
-    0,
-    NULL,
-    NULL,
+    &gcon_validate,
   },
 
   {
-    /* Q_GCON - GET_CONTAINER, v7 */
+    /* Q_GCON - GET_CONTAINER, v9 */
     "get_container",
     "gcon",
-    7,
+    9,
     RETRIEVE,
     "c",
     CONTAINERS_TABLE,
-    "name, description, location, contact, acl_type, acl_id, memacl_type, memacl_id, TO_CHAR(modtime, 'DD-mon-YYYY HH24:MI:SS'), modby, modwith FROM containers",
+    "name, publicflg, description, location, contact, acl_type, acl_id, memacl_type, memacl_id, TO_CHAR(modtime, 'DD-mon-YYYY HH24:MI:SS'), modby, modwith FROM containers",
     gcon_fields,
-    11,
-    "name = '%s' AND cnt_id != 0",
+    12,
+    "LOWER(name) LIKE LOWER('%s') AND cnt_id != 0",
     1,
     NULL,
     &gcon_validate,
@@ -7002,11 +7735,28 @@ struct query Queries[] = {
     "c",
     CONTAINERS_TABLE,
     "INTO containers (name, description, location, contact, acl_type, acl_id, memacl_type, memacl_id, cnt_id) VALUES ('%s', NVL('%s', CHR(0)), NVL('%s', CHR(0)), NVL('%s', CHR(0)), '%s', %d, '%s', %d, %s)",
-    acon_fields,
+    acon7_fields,
     8,
     0,
     0,
     NULL,
+    &acon7_validate,
+  },
+
+  {
+    /* Q_ACON - ADD_CONTAINER, v9 */ /* uses prefetch_value() for cnt_id */
+    "add_container",
+    "acon",
+    9,
+    APPEND,
+    "c",
+    CONTAINERS_TABLE,
+    "INTO containers (name, publicflg, description, location, contact, acl_type, acl_id, memacl_type, memacl_id, cnt_id) VALUES ('%s', %s, NVL('%s', CHR(0)), NVL('%s', CHR(0)), NVL('%s', CHR(0)), '%s', %d, '%s', %d, %s)",
+    acon_fields,
+    9,
+    0,
+    0,
+    NULL,
     &acon_validate,
   },
 
@@ -7019,11 +7769,28 @@ struct query Queries[] = {
     0,
     CONTAINERS_TABLE,
     0,
-    ucon_fields,
+    ucon7_fields,
     8,
     0,
     1,
     NULL,
+    &ucon7_validate,
+  },
+
+  {
+    /* Q_UCON - UPDATE_CONTAINER, v9 */
+    "update_container",
+    "ucon",
+    9,
+    UPDATE,
+    0,
+    CONTAINERS_TABLE,
+    0,
+    ucon_fields,
+    9,
+    0,
+    1,
+    NULL,
     &ucon_validate,
   },
 
@@ -7089,7 +7856,7 @@ struct query Queries[] = {
     "m.name, c.name FROM machine m, containers c, mcntmap mcn",
     gmnm_fields,
     2,
-    "m.name = UPPER('%s') AND mcn.cnt_id = c.cnt_id AND mcn.mach_id = m.mach_id",
+    "m.name LIKE UPPER('%s') AND mcn.cnt_id = c.cnt_id AND mcn.mach_id = m.mach_id",
     1,
     NULL,
     NULL,
@@ -7146,6 +7913,57 @@ struct query Queries[] = {
     NULL,
   },
 
+  {
+    /* Q_SCLI - SET_CONTAINER_LIST, v9 */
+    "set_container_list",
+    "scli",
+    9,
+    UPDATE,
+    0,
+    CONTAINERS_TABLE,
+    0,
+    scli_fields,
+    1,
+    0,
+    1,
+    NULL,
+    &scli_validate,
+  },
+
+  {
+    /* Q_GCLI - GET_CONTAINER_LIST, v9 */
+    "get_container_list",
+    "gcli",
+    9,
+    RETRIEVE,
+    "c",
+    CONTAINERS_TABLE,
+    "c.name, l.name FROM containers c, list l",
+    gcli_fields,
+    2,
+    "LOWER(c.name) = LOWER('%s') AND c.list_id = l.list_id AND c.list_id != 0",
+    1,
+    NULL,
+    NULL,
+  },
+
+  {
+    /* G_GLIC - GET_LIST_CONTAINER, v9 */
+    "get_list_container",
+    "glic",
+    9,
+    RETRIEVE,
+    "c",
+    CONTAINERS_TABLE,
+    "c.name, l.name FROM containers c, list l",
+    glic_fields,
+    2,
+    "l.list_id = %d AND l.list_id = c.list_id and c.list_id != 0",
+    1,
+    NULL,
+    &glic_validate,
+  },
+
 };
 
 int QueryCount = (sizeof(Queries) / sizeof(struct query));
This page took 0.152899 seconds and 4 git commands to generate.