Browse Source

TLS settings were not working

pdontthink 7 years ago
parent
commit
cc928acee3
2 changed files with 6 additions and 4 deletions
  1. 4 4
      plugins/administrator/defines.php
  2. 2 0
      plugins/administrator/options.php

+ 4 - 4
plugins/administrator/defines.php

@@ -129,7 +129,7 @@ $defcfg = array( '$config_version' => array( 'name' => _("Config File Version"),
                                                  'size' => 10,
                                                  'default' => 'detect' ),
                  '$use_imap_tls' => array( 'name' => _("IMAP Connection Security"),
-                                           'type' => SMOPT_TYPE_STRLIST,
+                                           'type' => SMOPT_TYPE_NUMLIST,
                                            'posvals' => array( 0 => _("Plain text connection"),
                                                                1 => _("Secure IMAP (TLS) connection"),
                                                                2 => _("IMAP STARTTLS connection")),
@@ -156,10 +156,10 @@ $defcfg = array( '$config_version' => array( 'name' => _("Config File Version"),
                  '$smtpPort' => array( 'name' => _("SMTP Server Port"),
                                        'type' => SMOPT_TYPE_INTEGER ),
                  '$use_smtp_tls' => array( 'name' => _("SMTP Connection Security"),
-                                           'type' => SMOPT_TYPE_STRLIST,
+                                           'type' => SMOPT_TYPE_NUMLIST,
                                            'posvals' => array( 0 => _("Plain text connection"),
-                                                               1 => _("Secure IMAP (TLS) connection"),
-                                                               2 => _("IMAP STARTTLS connection")),
+                                                               1 => _("Secure SMTP (TLS) connection"),
+                                                               2 => _("SMTP STARTTLS connection")),
                                            'comment' => _("Requires higher PHP version and special functions. See SquirrelMail documentation."),
                                            'default' => 0 ),
                  '$smtp_auth_mech' => array( 'name' => _("SMTP Authentication Type"),

+ 2 - 0
plugins/administrator/options.php

@@ -620,6 +620,8 @@ echo '<tr bgcolor="'.$color[5].'"><th colspan="2"><input value="'.
     Write the options to the file.
 */
 
+// Test/debug
+// $cfgfile = '/tmp/config.php';
 if ( $fp = @fopen( $cfgfile, 'w' ) ) {
     fwrite( $fp, "<?php\n".
     "/**\n".