mirror of
https://github.com/the-djmaze/snappymail.git
synced 2026-08-27 19:19:21 +03:00
#162 SpamAssassin "X-Spam-Status: No," is not spam and "X-Spam-Status: Yes," is spam
This commit is contained in:
parent
fd2304edcf
commit
2ceb036402
4 changed files with 7 additions and 5 deletions
|
|
@ -116,7 +116,7 @@ class MailClient
|
|||
\MailSo\Mime\Enumerations\Header::LIST_UNSUBSCRIBE,
|
||||
// SPAM
|
||||
\MailSo\Mime\Enumerations\Header::X_SPAM_STATUS,
|
||||
\MailSo\Mime\Enumerations\Header::X_SPAM_FLAG,
|
||||
// \MailSo\Mime\Enumerations\Header::X_SPAM_FLAG,
|
||||
\MailSo\Mime\Enumerations\Header::X_SPAMD_RESULT,
|
||||
\MailSo\Mime\Enumerations\Header::X_BOGOSITY,
|
||||
// Virus
|
||||
|
|
|
|||
|
|
@ -466,8 +466,9 @@ class Message implements \JsonSerializable
|
|||
$this->sSpamResult = "{$value[1]} / {$required[1]}";
|
||||
}
|
||||
}
|
||||
$spam = $oHeaders->ValueByName(\MailSo\Mime\Enumerations\Header::X_SPAM_FLAG);
|
||||
$this->bIsSpam = false !== \stripos($spam, 'YES');
|
||||
$this->bIsSpam = 0 === \strpos($spam, 'Yes,');
|
||||
// $spam = $oHeaders->ValueByName(\MailSo\Mime\Enumerations\Header::X_SPAM_FLAG);
|
||||
// $this->bIsSpam = false !== \stripos($spam, 'YES');
|
||||
}
|
||||
|
||||
if ($virus = $oHeaders->ValueByName(\MailSo\Mime\Enumerations\Header::X_VIRUS)) {
|
||||
|
|
|
|||
|
|
@ -59,6 +59,7 @@ abstract class Header
|
|||
X_SPAM_FLAG = 'X-Spam-Flag', // YES/NO
|
||||
X_SPAM_LEVEL = 'X-Spam-Level', // *******
|
||||
X_SPAM_STATUS = 'X-Spam-Status', // Yes|No
|
||||
X_SPAM_BAR = 'X-Spam-Bar', // ++
|
||||
// Rspamd
|
||||
X_SPAMD_RESULT = 'X-Spamd-Result', // default: False [7.13 / 9.00],
|
||||
X_SPAMD_BAR = 'X-Spamd-Bar', // +++++++
|
||||
|
|
|
|||
|
|
@ -56,8 +56,8 @@ class Header
|
|||
|
||||
private function initInputData(string $sName, string $sValue, string $sEncodedValueForReparse) : void
|
||||
{
|
||||
$this->sName = trim($sName);
|
||||
$this->sFullValue = trim($sValue);
|
||||
$this->sName = \trim($sName);
|
||||
$this->sFullValue = \trim($sValue);
|
||||
$this->sEncodedValueForReparse = '';
|
||||
|
||||
$this->oParameters = null;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue