Code

fixes: #1175
[gosa.git] / gosa-plugins / mail / personal / mail / sieve / class_sieve.inc
index 22b02e48aa231a0dd0e09e8905f69ca3d4f581a1..91c826f402b0c97d611ae825fa45ba11650e8177 100644 (file)
@@ -301,7 +301,7 @@ class sieve
     //response.  They repsond as follows: "Cyrus timsieved v1.0.0" "SASL={PLAIN,........}"
     //So, if we see IMLEMENTATION in the first line, then we are done.
 
-    if(ereg("IMPLEMENTATION",$this->line))
+    if(strstr($this->line, "IMPLEMENTATION"))
     {
       //we're on the Cyrus V2 sieve server
       while(sieve::status($this->line) == F_DATA){
@@ -394,7 +394,7 @@ class sieve
     }
 
     /* Fill error message if no auth types are present */
-    if (!isset($this->capabilities["auth"])){
+    if (($this->options != "tls") && (!isset($this->capabilities["auth"]))){
       $this->error=EC_UNKNOWN;
       $this->error_raw = "No authentication methods found - please check your sieve setup for missing sasl modules";
       return false;