- Secure vcard export by getting rid of preg's 'e' modifier use (#1485689)

release-0.6
alecpl 16 years ago
parent b7c1685b2d
commit 478c7c63d8

@ -4,6 +4,7 @@ CHANGELOG RoundCube Webmail
2009/01/18 (alec)
----------
- Fix problems with backslash as IMAP hierarchy delimiter (#1484467)
- Secure vcard export by getting rid of preg's 'e' modifier use (#1485689)
2009/01/15 (alec)
----------

@ -226,10 +226,14 @@ class rcube_vcard
return $vcard;
}
private static function rfc2425_fold_callback($matches)
{
return ":\n ".rtrim(chunk_split($matches[1], 72, "\n "));
}
private static function rfc2425_fold($val)
{
return preg_replace('/:([^\n]{72,})/e', '":\n ".rtrim(chunk_split("\\1", 72, "\n "))', $val) . "\n";
return preg_replace_callback('/:([^\n]{72,})/', 'self::rfc2425_fold_callback', $val) . "\n";
}

Loading…
Cancel
Save