• Our team is looking to connect with folks who use email services provided by Plesk, or a premium service. If you'd like to be part of the discovery process and share your experiences, we invite you to complete this short screening survey. If your responses match the persona we are looking for, you'll receive a link to schedule a call at your convenience. We look forward to hearing from you!
  • We are looking for U.S.-based freelancer or agency working with SEO or WordPress for a quick 30-min interviews to gather feedback on XOVI, a successful German SEO tool we’re looking to launch in the U.S.
    If you qualify and participate, you’ll receive a $30 Amazon gift card as a thank-you. Please apply here. Thanks for helping shape a better SEO product for agencies!
  • The BIND DNS server has already been deprecated and removed from Plesk for Windows.
    If a Plesk for Windows server is still using BIND, the upgrade to Plesk Obsidian 18.0.70 will be unavailable until the administrator switches the DNS server to Microsoft DNS. We strongly recommend transitioning to Microsoft DNS within the next 6 weeks, before the Plesk 18.0.70 release.
  • The Horde component is removed from Plesk Installer. We recommend switching to another webmail software supported in Plesk.

Question Spammer in the server, how to find him

SalvadorS

Regular Pleskian
Server operating system version
Debian 11
Plesk version and microupdate number
18.0.55
Hello,

I have these lines in mail mail.info log:



Oct 17 09:46:35 dv7 postfix/smtpd[4021867]: connect from localhost[127.0.0.1]
Oct 17 09:46:35 dv7 postfix/smtpd[4021864]: NOQUEUE: reject: RCPT from localhost[127.0.0.1]: 554 5.7.1 <[email protected]>: Relay access denied; from=<[email protected]> to=<[email protected]> proto=ESMTP helo=<xxx.server.com>
Oct 17 09:46:35 dv7 postfix/smtpd[4021864]: lost connection after RCPT from localhost[127.0.0.1]
Oct 17 09:46:35 dv7 postfix/smtpd[4021864]: disconnect from localhost[127.0.0.1] ehlo=1 mail=1 rcpt=0/1 commands=2/3

So I think localhost is webmail, but how can I find which mailbox is doing this? As from header is false....
 
Hi Peter,

Thanks for your reponse, always useful.

The problem here is that the mail queue is empty and I check all the POST headers in the logs and I don´t find anything.

So I don´t know if that log is telling that a mail is sent from the server, as I see rejected. What is your opinion?
 
If you are sure that no script is sending the mails through the regular mail server, you can check the process list of Linux whether you find a suspicious process. Especially on systems where /tmp has not been secured against script execution one attack vector is to place a stand-alone mailer like Exim there and run it. This will bypass all stats and the regular Postfix mailer. The mailer does not necessarily have to be named Exim, it can have any name, but it will need to use port 25, so there is your next step for a deeper analysis.
 
If you are sure that no script is sending the mails through the regular mail server, you can check the process list of Linux whether you find a suspicious process. Especially on systems where /tmp has not been secured against script execution one attack vector is to place a stand-alone mailer like Exim there and run it. This will bypass all stats and the regular Postfix mailer.
However in that case they wouldn't show up in the maillog.

The problem here is that the mail queue is empty and I check all the POST headers in the logs and I don´t find anything.
So I don´t know if that log is telling that a mail is sent from the server, as I see rejected. What is your opinion?
Something tries to send a mail but gets rightfully rejected. Thankfully they're stupid (if they used a local mail address for the From, it wouldn't get blocked as Relaying).
As it gets rejected right at the start of the SMTP dialog, even before the body data is sent, the mail doesn't even reach the queue, so it can't show up in `postqueue -p`.
 
Back
Top