summaryrefslogtreecommitdiff
path: root/lib/KolabAdmin
diff options
context:
space:
mode:
authorGunnar Wrobel <wrobel@pardus.de>2010-03-31 21:05:43 (GMT)
committerGunnar Wrobel <wrobel@pardus.de>2010-03-31 21:05:43 (GMT)
commit9835db6ac69e334c3e0dafab1cf4885f233370ac (patch)
tree0266eeffd6bbce1b5b1ae52f11619b81c73235ff /lib/KolabAdmin
parent8cd08ffc789dd67d940fab2d9e422776877cc985 (diff)
downloadkolab-webadmin-9835db6ac69e334c3e0dafab1cf4885f233370ac.tar.gz
Allow successful writing/reparsing of the generated script. This simplyfies the modified regexes and they should be made more secure later again.
Diffstat (limited to 'lib/KolabAdmin')
-rw-r--r--lib/KolabAdmin/Sieve/Script.php4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/KolabAdmin/Sieve/Script.php b/lib/KolabAdmin/Sieve/Script.php
index 03e177c..98e609b 100644
--- a/lib/KolabAdmin/Sieve/Script.php
+++ b/lib/KolabAdmin/Sieve/Script.php
@@ -51,7 +51,7 @@ class KolabAdmin_Sieve_Script {
/*static*/ function getMailDomain( $script ) {
$maildomain = false;
- if( preg_match( '/if not address :domain :contains "From" "(.*)" { keep; stop; }/i', $script, $regs ) ) {
+ if( preg_match( '/address :domain :contains "From" "(.*)"/i', $script, $regs ) ) {
$maildomain = $regs[1];
}
return $maildomain;
@@ -59,7 +59,7 @@ class KolabAdmin_Sieve_Script {
/*static*/ function getReactToSpam( $script ) {
$spam = false;
- if( preg_match('/if header :contains "X-Spam-Flag" "YES" { keep; stop; }/i', $script ) ) {
+ if( preg_match('/header :contains "X-Spam-Flag" "YES"/i', $script ) ) {
$spam = true;
}
return $spam;