Qmail (Plesk) vermutlich kompromittiert



dbhomers

New Member
Hi, ich vermute mein Server wurde kompromittiert finde aber nichts, bin für jeden Tipp dankbar.

System: Plesk 12 (Debian Wheezy); Postausgang: qmail; Posteingang: dovecot

Das Problem: ab und zu, wenn man über den Server eine Mail von A nach B versendet bekommt man von qmail eine Rückmeldung dass die Nachricht an verschiedene andere Adressen nicht zugestellt werden konnte. Es sind keine Weiterleitungen eingerichtet oder Maillist oder ähnliches.

Die Meldung kam bei verschiedenen Mailadressen (unterschiedliche Domains) auch bei Nachrichten die direkt vom Server (cronjob) versendet wurden via mail command.

Das kuriose, ich kann auf dem Server leider nichts finden, habe mir alle qmail config Dateien angeguckt. Die Dateien haben auch alle ein Datum (letzte Änderung) von 2015/2016 ich weiß dass man das ändern kann aber habe wie gesagt in den Dateien auch nichts auffälliges gefunden.

Hinzu kommt dass ich auch in den maillogs nichts ungewöhnliches finde, auch nicht den Versuch der Zustellung an die anderen E-Mailkonten.

Ich habe den gesammten Server nach Dateien durchsucht, welche die Adressen enthalten könnten, habe aber nichts gefunden. Könnten natürlich codiert sein, so dass ich sie gar nicht finden kann.

Nachfolgend die Mitteilung von qmail, die Dateien sind anonymisiert.
meinedomain.de = ist die Domain die auf meinem Server zeigt
externedomain.de = ist die Empfänger Domain
999.999.999.999 = IP von meinem Arbeitsplatz
888.888.888.888 = IP des Empfängers

Code:
Hi. This is the qmail-send program at mail.meinedomain.de.
I'm afraid I wasn't able to deliver your message to the following addresses.
This is a permanent error; I've given up. Sorry it didn't work out.

<[email protected]>:
2a00:1450:400c:0c0c:0000:0000:0000:001a does not like recipient.
Remote host said: 550-5.1.1 The email account that you tried to reach does not exist. Please try
550-5.1.1 double-checking the recipient's email address for typos or
550-5.1.1 unnecessary spaces. Learn more at
550 5.1.1  https://support.google.com/mail/?p=NoSuchUser p66-v6si1784651wme.58 - gsmtp
Giving up on 2a00:1450:400c:0c0c:0000:0000:0000:001a.

<[email protected]>:
2a00:1450:400c:0c0c:0000:0000:0000:001b does not like recipient.
Remote host said: 550-5.1.1 The email account that you tried to reach does not exist. Please try
550-5.1.1 double-checking the recipient's email address for typos or
550-5.1.1 unnecessary spaces. Learn more at
550 5.1.1  https://support.google.com/mail/?p=NoSuchUser h64-v6si2542606wma.160 - gsmtp
Giving up on 2a00:1450:400c:0c0c:0000:0000:0000:001b.

<[email protected]>:
2a00:1450:400c:0c0c:0000:0000:0000:001a does not like recipient.
Remote host said: 550-5.1.1 The email account that you tried to reach does not exist. Please try
550-5.1.1 double-checking the recipient's email address for typos or
550-5.1.1 unnecessary spaces. Learn more at
550 5.1.1  https://support.google.com/mail/?p=NoSuchUser d5-v6si2914688wme.132 - gsmtp
Giving up on 2a00:1450:400c:0c0c:0000:0000:0000:001a.

<[email protected]>:
2a00:1450:400c:0c0c:0000:0000:0000:001a does not like recipient.
Remote host said: 550-5.1.1 The email account that you tried to reach does not exist. Please try
550-5.1.1 double-checking the recipient's email address for typos or
550-5.1.1 unnecessary spaces. Learn more at
550 5.1.1  https://support.google.com/mail/?p=NoSuchUser u136-v6si2294889wmu.169 - gsmtp
Giving up on 2a00:1450:400c:0c0c:0000:0000:0000:001a.

<[email protected]>:
74.208.5.20 does not like recipient.
Remote host said: 550 Requested action not taken: mailbox unavailable
Giving up on 74.208.5.20.

<[email protected]>:
67.195.228.87 failed after I sent the message.
Remote host said: 554 delivery error: dd This user doesn't have a aol.com account ([email protected]) [-9] - mta4178.aol.mail.gq1.yahoo.com

--- Below this line is a copy of the message.

Return-Path: <[email protected]>
Received: (qmail 9529 invoked from network); 14 Aug 2018 14:43:04 +0200
Received: from softdnserror (HELO ?192.168.178.23?) (999.999.999.999)
 by mail.meinedomain.de with ESMTPSA (AES128-SHA encrypted, authenticated);
 14 Aug 2018 14:43:04 +0200
Subject: Re: Fwd: Emailprobleme
From: Hans Muster <[email protected]>
To: Hanni Pattern <[email protected]>
References: <[email protected]>
 <[email protected]>
 <[email protected]>
Message-ID: <[email protected]>
Date: Tue, 14 Aug 2018 14:43:39 +0200
User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:60.0) Gecko/20100101
 Thunderbird/60.0
MIME-Version: 1.0
In-Reply-To: <[email protected]>
Content-Type: multipart/signed; protocol="application/pkcs7-signature";
 micalg=sha-256; boundary="------------ms020606020200070700070008"
X-PPP-Message-ID: <[email protected]>
X-PPP-Vhost: meinedomain.de

Email Nachricht ....


Und der Ausschnitt aus der maillog:
Code:
Aug 14 14:35:16 mail qmail-queue-handlers[8037]: Handlers Filter before-queue for qmail started ...
Aug 14 14:35:17 mail qmail-queue-handlers[8037]: [email protected]
Aug 14 14:35:17 mail qmail-queue-handlers[8037]: [email protected]
Aug 14 14:35:17 mail qmail-queue-handlers[8037]: [email protected]
Aug 14 14:35:17 mail qmail-queue-handlers[8037]: handlers_stderr: SKIP
Aug 14 14:35:17 mail qmail-queue-handlers[8037]: SKIP during call 'grey' handler
Aug 14 14:35:17 mail qmail-queue-handlers[8037]: handlers_stderr: SKIP
Aug 14 14:35:17 mail qmail-queue-handlers[8037]: SKIP during call 'grey' handler
Aug 14 14:35:17 mail qmail-queue-handlers[8037]: handlers_stderr: PASS
Aug 14 14:35:17 mail qmail-queue-handlers[8037]: PASS during call 'limit-out' handler
Aug 14 14:35:17 mail qmail-queue-handlers[8037]: handlers_stderr: SKIP
Aug 14 14:35:17 mail qmail-queue-handlers[8037]: SKIP during call 'check-quota' handler
Aug 14 14:35:18 mail qmail-queue-handlers[8037]: starter: submitter[8042] exited normally
Aug 14 14:35:18 mail qmail: 1534250118.085343 new msg 3065551
Aug 14 14:35:18 mail qmail: 1534250118.085366 info msg 3065551: bytes 21735 from <[email protected]> qp 8042 uid 2020
Aug 14 14:35:18 mail qmail: 1534250118.572926 starting delivery 4791: msg 3065551 to local [email protected]
Aug 14 14:35:18 mail qmail: 1534250118.572958 status: local 1/10 remote 0/20
Aug 14 14:35:18 mail qmail: 1534250118.572972 starting delivery 4792: msg 3065551 to remote [email protected]
Aug 14 14:35:18 mail qmail: 1534250118.572993 status: local 1/10 remote 1/20
Aug 14 14:35:18 mail qmail-remote-handlers[8045]: Handlers Filter before-remote for qmail started ...
Aug 14 14:35:18 mail qmail-local-handlers[8046]: Handlers Filter before-local for qmail started ...
Aug 14 14:35:18 mail qmail-local-handlers[8046]: [email protected]
Aug 14 14:35:18 mail qmail-remote-handlers[8045]: [email protected]
Aug 14 14:35:18 mail qmail-remote-handlers[8045]: [email protected]
Aug 14 14:35:18 mail qmail-local-handlers[8046]: [email protected]
Aug 14 14:35:18 mail qmail-local-handlers[8046]: mailbox: /var/qmail/mailnames/meinedomain.de/info
Aug 14 14:35:18 mail spamd[4954]: spamd: connection from ip6-localhost [::1]:56450 to port 783, fd 6
Aug 14 14:35:18 mail spamd[4954]: spamd: using default config for [email protected]: /var/qmail/mailnames/meinedomain.de/info/.spamassassin/user_prefs
Aug 14 14:35:18 mail spamd[4954]: spamd: processing message <[email protected]> for [email protected]:30
Aug 14 14:35:19 mail dovecot: service=imap, [email protected], ip=[999.999.999.999]. Disconnected: Disconnected in IDLE rcvd=23142, sent=5225
Aug 14 14:35:19 mail qmail: 1534250119.212004 delivery 4792: success: 888.888.888.888_accepted_message./Remote_host_said:_250_2.0.0_Ok:_queued_as_0E5D74246D07/
Aug 14 14:35:19 mail qmail: 1534250119.212082 status: local 1/10 remote 0/20
Aug 14 14:35:19 mail spamd[4954]: spamd: clean message (-2.9/7.0) for [email protected]:30 in 0.5 seconds, 21735 bytes.
Aug 14 14:35:19 mail spamd[4954]: spamd: result: . -2 - ALL_TRUSTED,BAYES_00,HTML_MESSAGE,URIBL_BLOCKED scantime=0.5,size=21735,[email protected],uid=30,required_score=7.0,rhost=ip6-localhost,raddr=::1,rport=56450,mid=<[email protected]>,bayes=0.000000,autolearn=ham autolearn_force=no
Aug 14 14:35:19 mail spamd[17356]: prefork: child states: II
Aug 14 14:35:19 mail dovecot: service=lda, [email protected], ip=[]. msgid=<[email protected]>: saved mail to INBOX
Aug 14 14:35:19 mail qmail: 1534250119.587216 delivery 4791: success: did_0+0+2/
Aug 14 14:35:19 mail qmail: 1534250119.587288 status: local 0/10 remote 0/20
Aug 14 14:35:19 mail qmail: 1534250119.587303 end msg 3065551
 
Ist das

Received: from softdnserror (HELO ?192.168.178.23?) (999.999.999.999)

deine LAN bzw. öffentliche IP? Und du nutzt

User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:60.0) Gecko/20100101
Thunderbird/60.0

? Dann würde ich mal sagen, dass dein Rechner Viren-/Trojanerversucht ist.
 
Ja, das ist meine IP und mein Client.

Das Problem trat aber auch auf als Mails in der bash via mail (heirloom-mailx) versendet wurden. Die binary auf dem Server ist unverändert und original aus dem repository.

[edit]
OK, jetzt gerade fällt mir auf dass in der mail "In-Reply-To: <[email protected]>" steht.
Dass ist die BCC Adresse an der ich ne Kopie gesendet habe und an der auch die Mails vom Cronjob gesendet werden. Möglicherweise ist ein Client, der diese Mail abruft infiziert. Dass werde ich morgen erst einmal testen.
 
Last edited by a moderator:
Back
Top