• If you are still using CentOS 7.9, it's time to convert to Alma 8 with the free centos2alma tool by Plesk or Plesk Migrator. Please let us know your experiences or concerns in this thread:
    CentOS2Alma discussion

Forwarded to devs Train spamassasing using localhost

Frank.P

Regular Pleskian
TITLE:
Train spamassasing using localhost
PRODUCT, VERSION, OPERATING SYSTEM, ARCHITECTURE:
Windows , Plesk 17.5
PROBLEM DESCRIPTION:
PHP LOG : C:\Program Files (x86)\Plesk\admin\logs\php_error.log

Code:
[2017-08-16 03:12:03] ERR [1] PHP Warning: imap_open(): Couldn't open stream {127.0.0.1:143}Inbox\Spam; File: C:\Program Files (x86)\Plesk\admin\plib\Spamassassin\adapter\Imap.php, Line: 36

[2017-08-16 03:12:03] ERR [panel] Failed to train sa for mailname emailmydomain.net: Failed to connect to imap server. : Certificate failure for 127.0.0.1: Server name does not match certificate: CN=mydomain.com


Plesk conect to localhost and ask command "STARTTLS" , if wrong response connet to IMAP without certificate, buy if answer is right connect using TLS for secure connection.

The problem is local ip 127.0.0.1 never have a valid certificate, becase certificate only can have a domain name.

Please change C:\Program Files (x86)\Plesk\admin\plib\Spamassassin\adapter\Imap.php and never connect to IMAP using TLS.
STEPS TO REPRODUCE:
1- Create 2 or more domains.
2. Set by default a certificate
2- Set for first ip a certificate (same of default for example)
3- In second ip set an other certificate


img1.png img2.png

ACTUAL RESULT:
PHP ERROR and not connect because server name does not match certificate
EXPECTED RESULT:
Change C:\Program Files (x86)\Plesk\admin\plib\Spamassassin\adapter\Imap.php

YOUR EXPECTATIONS FROM PLESK SERVICE TEAM:
Confirm bug
 
From developer:

It looks like some sort of misconfiguration. We do not use Imap for train SpamAssassin in case of mailenable mail server.
Try to refresh server components.
 
Back
Top