Forward email flagged as spam by spamassasin

Operating System & Version
Centos 6.10
cPanel & WHM Version
86.0.24

samuelmf

Well-Known Member
May 22, 2006
125
6
168
Perú
Hi i have installed manually the last version of roundcube due to i cant have the latest version by cpanel because my server have centos 6 and cannot update to the latest cpanel version that comes with the new rouncube version.

The situation is that when i try to forward an email with ***SPAM*** i cannot deliver it, and the rouncube window remains on Sending... and finally get a timeout or recieve a message like:
Error SMTP: 550 This message was classified as SPAM and may not be delivered.

A rare thing is thats when i login to the stock roundcube (the old one) that is on my cpanel server and try to forward the same message that i'm trying to forward on the manually installed roundcube by me, and the message is sent with no problem.

Is possible to configure exim to avoid scan outgoing messages for spam?
I know that rouncube is a third party software but it's very rare that the old rc that comes with cpanel con forward messages flagged as spam and the new one installed cant.
 

Michael Svendsen

Well-Known Member
Dec 19, 2016
75
20
83
Denmark
cPanel Access Level
Root Administrator
Hi,

First - I cannot recommend enough that you should upgrade as soon as possible Centos 6 EOL is just around the corner and nowadays - depending on your setup - it's relatively easy migrating to a new server.

Now to your issue:

- How did you install and configure Roundcube?
- In your Exim Configuration Manager, if you look under Apache Spamassasin tab, have you enabled outgoing spam scanning? (Disabled by default)?
 

samuelmf

Well-Known Member
May 22, 2006
125
6
168
Perú
Hi, thabks for reply
I have this settings under SpamAssasin on exim configuration

I have installed manually with the tar file, extracted it to a folder and then used the install folder.

on the config file i have this
Code:
// ----------------------------------
// SMTP
// ----------------------------------
// SMTP server host (for sending mails).
// Enter hostname with prefix ssl:// to use Implicit TLS, or use
// prefix tls:// to use STARTTLS.
// Supported replacement variables:
// %h - user's IMAP hostname
// %n - hostname ($_SERVER['SERVER_NAME'])
// %t - hostname without the first part
// %d - domain (http hostname $_SERVER['HTTP_HOST'] without the first part)
// %z - IMAP domain (IMAP hostname without the first part)
// For example %n = mail.domain.tld, %t = domain.tld
$config['smtp_server'] = 'mail.mydomain.gob.pe';
Code:
// ----------------------------------
// IMAP
// ----------------------------------
// The IMAP host chosen to perform the log-in.
// Leave blank to show a textbox at login, give a list of hosts
// to display a pulldown menu or set one host as string.
// Enter hostname with prefix ssl:// to use Implicit TLS, or use
// prefix tls:// to use STARTTLS.
// Supported replacement variables:
// %n - hostname ($_SERVER['SERVER_NAME'])
// %t - hostname without the first part
// %d - domain (http hostname $_SERVER['HTTP_HOST'] without the first part)
// %s - domain name after the '@' from e-mail address provided at login screen
// For example %n = mail.domain.tld, %t = domain.tld
// WARNING: After hostname change update of mail_host column in users table is
//          required to match old user data records with the new host.
$config['default_host'] = 'ssl://mail.mydomain.gob.pe';

// TCP port used for IMAP connections
$config['default_port'] = 993;
When i send an email it sents fine, with no problem, even to normal emails if i forward them, it works fine
The problem is only with the mails that have spam flags on mail headers.
Code:
X-Spam-Status: Yes, score=7.3
X-Spam-Score: 73
X-Spam-Bar: +++++++
X-Spam-Report: Spam detection software, running on the system
X-Spam-Flag: YES
Subject: ***SPAM*** Constancia de deposito por detracciones 116149635
X-From-Rewrite: unmodified, no actual sender determined from check mail permissions
 

Michael Svendsen

Well-Known Member
Dec 19, 2016
75
20
83
Denmark
cPanel Access Level
Root Administrator
I don't have much experience with customized webmail installs on cPanel - but maybe replacing the server names with "localhost" will help. Just a guess.

Also, I can see that you have enabled "Do not forward mail to external recipients based on the defined Apache SpamAssassin". Have you tried disabling that?
 

Michael Svendsen

Well-Known Member
Dec 19, 2016
75
20
83
Denmark
cPanel Access Level
Root Administrator
Ok - probably because of SSL/TLS verify (as it cannot verify localhost).
Did you try disabling the "Do not forward mail..." ?
 

cPanelLauren

Technical Support Community Manager
Staff member
Nov 14, 2017
12,366
1,126
313
Houston
HI @samuelmf

Sorry to hear you're still having this trouble. Because you installed a custom version of roundcube the installation is not something that is supported by cPanel and its behavior will be completely different than cPanel's roundcube as it's not integrated.

What I would imagine is happening is Roundcube's own spam filtering or a plugin is looking at X-Spam headers and making decisions on allowed actions based on their presence. What I would suggest you do to troubleshoot the custom roundcube installation further if you're unaware which portion of the software is doing this is to go through their support documentation here:

Or make use of their community forums here:

They also have a mailing list here:

Thank you
 

samuelmf

Well-Known Member
May 22, 2006
125
6
168
Perú
@cPanelLauren seems that i've discovered the cause for the problem when forwarding messages, the problem apparently is caused by wordfence wordpress plugin, i've disabled it and now i can forward emails.

Just for test pourposes i've enabled it again and the hang "sending..." message back again and get timeout.

I disabled wordfence and now i'm able to forward messages
I will look on the wordfence rules to put my domain on whitelist
 
  • Like
Reactions: cPanelLauren