The 'master user' account and password may now
authorArt Cancro <ajc@citadel.org>
Fri, 21 Sep 2007 16:25:34 +0000 (16:25 +0000)
committerArt Cancro <ajc@citadel.org>
Fri, 21 Sep 2007 16:25:34 +0000 (16:25 +0000)
be configured using either the text mode client or WebCit.
The 'check RBLs upon connect' option wasn't configured
in WebCit, this has been fixed.

citadel/modules/pop3/serv_pop3.c
citadel/routines2.c
webcit/siteconfig.c

index 74b3255c957c74563bb3674fc657268afee5798c..e8f975c4dc5999508a6db56ed31aea114f86a0c6 100644 (file)
@@ -98,9 +98,14 @@ void pop3_greeting(void) {
  */
 void pop3s_greeting(void) {
        CtdlModuleStartCryptoMsgs(NULL, NULL, NULL);
+
+/* kill session if no crypto */
 #ifdef HAVE_OPENSSL
-       if (!CC->redirect_ssl) CC->kill_me = 1;         /* kill session if no crypto */
+       if (!CC->redirect_ssl) CC->kill_me = 1;
+#else
+       CC->kill_me = 1;
 #endif
+
        pop3_greeting();
 }
 
index 93c1814e51d7003a445a72f3b41e577704c77379..346b3ea62fe6375c9e72ec85b563715372eb836b 100644 (file)
@@ -649,7 +649,7 @@ void read_bio(CtdlIPC *ipc)
 void do_system_configuration(CtdlIPC *ipc)
 {
 
-#define NUM_CONFIGS 58
+#define NUM_CONFIGS 60
 
        char buf[256];
        char sc[NUM_CONFIGS][256];
@@ -780,7 +780,7 @@ void do_system_configuration(CtdlIPC *ipc)
        if (ipc->ServInfo.supports_ldap) {
                a = strlen(&sc[32][0]);
                a = (a ? 1 : 0);        /* Set only to 1 or 0 */
-               a = boolprompt("Connect this Citadel to an LDAP directory", a);
+               a = boolprompt("Connect this Citadel to an external LDAP directory", a);
                if (a) {
                        strprompt("Host name of LDAP server",
                                &sc[32][0], 127);
@@ -870,11 +870,35 @@ void do_system_configuration(CtdlIPC *ipc)
        }
 
        /* Funambol push stuff */
-       strprompt("Funambol server (blank to disable)", &sc[53][0], 63);
-       strprompt("Funambol server port", &sc[54][0], 5);
-       strprompt("Funambol sync source", &sc[55][0], 63);
-       strprompt("Funambol authentication details (user:pass in Base64)", &sc[56][0],63);
-       
+       int yes_funambol = 0;
+       if (strlen(sc[53]) > 0) yes_funambol = 1;
+       yes_funambol = boolprompt("Connect to an external Funambol sync server", yes_funambol);
+       if (yes_funambol) {
+               strprompt("Funambol server (blank to disable)", &sc[53][0], 63);
+               strprompt("Funambol server port", &sc[54][0], 5);
+               strprompt("Funambol sync source", &sc[55][0], 63);
+               strprompt("Funambol authentication details (user:pass in Base64)", &sc[56][0],63);
+       }
+       else {
+               sc[53][0] = 0;
+               sc[54][0] = 0;
+               sc[55][0] = 0;
+               sc[56][0] = 0;
+       }
+
+       /* Master user account */
+       int yes_muacct = 0;
+       if (strlen(sc[58]) > 0) yes_muacct = 1;
+       yes_muacct = boolprompt("Enable a 'master user' account", yes_muacct);
+       if (yes_muacct) {
+               strprompt("Master user name", &sc[58][0], 31);
+               strprompt("Master user password", &sc[59][0], -31);
+       }
+       else {
+               strcpy(&sc[58][0], "");
+               strcpy(&sc[59][0], "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx");
+       }
+
        /* Save it */
        scr_printf("Save this configuration? ");
        if (yesno()) {
index 1198fd056dea668dd400f4902060dfaa343e377b..236e93194a72e59a8f55a662cf1b3b15318154d4 100644 (file)
@@ -561,6 +561,29 @@ void display_siteconfig(void)
                        sprintf(&funambol[strlen(funambol)], "<input type=\"text\" NAME=\"c_funambol_auth\" MAXLENGTH=\"255\" VAUE=\"%s\">", buf);
                        sprintf(&funambol[strlen(funambol)], "</TD></TR>\n");
                        break;
+               case 57:
+                       sprintf(&network[strlen(network)], "<TR><TD>");
+                       sprintf(&network[strlen(network)], _("Perform RBL checks upon connect instead of after RCPT"));
+                       sprintf(&network[strlen(network)], "</TD><TD>");
+                       sprintf(&network[strlen(network)], "<input type=\"checkbox\" NAME=\"c_rbl_at_greeting\" VALUE=\"yes\" %s>",
+                               ((atoi(buf) != 0) ? "CHECKED" : ""));
+                       sprintf(&network[strlen(network)], "</TD></TR>\n");
+                       break;
+               case 58:
+                       sprintf(&access[strlen(access)], "<TR><TD>");
+                       sprintf(&access[strlen(access)], _("Master user name (blank to disable)"));
+                       sprintf(&access[strlen(access)], "</TD><TD>");
+                       sprintf(&access[strlen(access)], "<input type=\"text\" NAME=\"c_master_user\" MAXLENGTH=\"31\" VALUE=\"%s\">", buf);
+                       sprintf(&access[strlen(access)], "</TD></TR>\n");
+                       break;
+               case 59:
+                       sprintf(&access[strlen(access)], "<TR><TD>");
+                       sprintf(&access[strlen(access)], _("Master user password"));
+                       sprintf(&access[strlen(access)], "</TD><TD>");
+                       sprintf(&access[strlen(access)], "<input type=\"password\" NAME=\"c_master_pass\" MAXLENGTH=\"31\" VALUE=\"%s\">",
+                       buf);
+                       sprintf(&directory[strlen(directory)], "</TD></TR>\n");
+                       break;
                }
        
        }
@@ -732,6 +755,9 @@ void siteconfig(void)
        serv_printf("%s", bstr("c_funambol_port"));
        serv_printf("%s", bstr("c_funambol_source"));
        serv_printf("%s", bstr("c_funambol_auth"));
+       serv_printf("%s", bstr("c_rbl_at_greeting"));
+       serv_printf("%s", bstr("c_master_user"));
+       serv_printf("%s", bstr("c_master_pass"));
        serv_printf("000");
 
        serv_printf("SPEX site|%d|%d", atoi(bstr("sitepolicy")), atoi(bstr("sitevalue")));