mirror of
https://bitbucket.org/jsuto/piler.git
synced 2024-11-07 22:41:59 +01:00
Revert "Improved sanitizing the restored emails"
This reverts commit bace954070
.
This commit is contained in:
parent
bace954070
commit
001453cef6
@ -12,8 +12,6 @@ class ModelMailMail extends Model {
|
||||
|
||||
if($to == "" || strlen($msg) < 30){ return $ok; }
|
||||
|
||||
$msg = $this->normalize_message($msg);
|
||||
|
||||
if(REWRITE_MESSAGE_ID == 1) {
|
||||
$msg = preg_replace("/Message-ID:([^\n]+)\n/i", "Message-ID: <" . generate_random_string(25) . '@' . SITE_NAME . ">\n", $msg);
|
||||
}
|
||||
@ -167,8 +165,4 @@ class ModelMailMail extends Model {
|
||||
}
|
||||
|
||||
|
||||
private function normalize_message($data = '') {
|
||||
$a = preg_split("/\r?\n/", $data);
|
||||
return implode("\r\n", $a);
|
||||
}
|
||||
}
|
||||
|
@ -40,6 +40,12 @@ class ModelSearchMessage extends Model {
|
||||
}
|
||||
|
||||
|
||||
private function normalize_message($data = '') {
|
||||
$a = preg_split("/\r?\n/", $data);
|
||||
return implode("\r\n", $a);
|
||||
}
|
||||
|
||||
|
||||
public function get_raw_message($id = '') {
|
||||
$s = '';
|
||||
|
||||
@ -65,6 +71,8 @@ class ModelSearchMessage extends Model {
|
||||
$this->verification = $this->verify_message($id, $s);
|
||||
}
|
||||
|
||||
$s = $this->normalize_message($s);
|
||||
|
||||
if(Registry::get('auditor_user') == 0 && HEADER_LINE_TO_HIDE) {
|
||||
$s = preg_replace("/" . HEADER_LINE_TO_HIDE . ".{1,}(\n(\ |\t){1,}.{1,}){0,}" . "\n/i", "", $s);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user