E-Mail´s Greylisted but Greylisting not activated

Discussion in 'ISPConfig 3 Priority Support' started by ktownmods, Aug 25, 2019.

  1. ktownmods

    ktownmods Member

    Hey, here is my log:

    in there you see
    Code:
    Aug 25 16:57:20 mail postgrey[946]: action=greylist, reason=new, client_name=relay06.alfahosting-server.de
    here an screenshot that Greylisting isnt enabled:

    Screenshot_453.png

    Why it Greylisting?


    Code:
    Aug 25 16:57:20 mail postfix/smtpd[29934]: NOQUEUE: filter: RCPT from relay06.alfahosting-server.de[109.237.XXX.XXX]: <[email protected]>: Sender address triggers FILTER amavis:[127.0.0.1]:10026; from=<[email protected]> to=<[email protected]> proto=ESMTP helo=<relay06.alfahosting-server.de>
    Aug 25 16:57:20 mail postfix/smtpd[29934]: NOQUEUE: filter: RCPT from relay06.alfahosting-server.de[109.237.XXX.XXX]: <[email protected]>: Sender address triggers FILTER amavis:[127.0.0.1]:10024; from=<[email protected]> to=<[email protected]> proto=ESMTP helo=<relay06.alfahosting-server.de>
    Aug 25 16:57:20 mail postfix/smtpd[29934]: warning: 242.142.237.109.zen.spamhaus.org: RBL lookup error: Host or domain name not found. Name service error for name=242.142.237.109.zen.spamhaus.org type=A: Host not found, try again
    Aug 25 16:57:20 mail postgrey[946]: action=greylist, reason=new, client_name=relay06.alfahosting-server.de, client_address=109.237.XXX.XXX/32, [email protected], [email protected]
    Aug 25 16:57:20 mail postgrey[946]: cleaning up old logs...
    Aug 25 16:57:20 mail postfix/smtpd[29934]: NOQUEUE: reject: RCPT from relay06.alfahosting-server.de[109.237.XXX.XXX]: 450 4.2.0 <[email protected]>: Recipient address rejected: Greylisted, see http://postgrey.schweikert.ch/help/example.de.html; from=<[email protected]> to=<[email protected]> proto=ESMTP helo=<relay06.alfahosting-server.de>
    Aug 25 16:57:20 mail postfix/smtpd[29934]: disconnect from relay06.alfahosting-server.de[109.237.XXX.XXX] ehlo=2 starttls=1 mail=1 rcpt=0/1 data=0/1 rset=1 quit=1 commands=6/8
    Aug 25 16:57:20 mail postfix/smtpd[29934]: connect from relay06.alfahosting-server.de[109.237.XXX.XXX]
    Aug 25 16:57:20 mail postfix/smtpd[29934]: NOQUEUE: filter: RCPT from relay06.alfahosting-server.de[109.237.XXX.XXX]: <[email protected]>: Sender address triggers FILTER amavis:[127.0.0.1]:10026; from=<[email protected]> to=<[email protected]> proto=ESMTP helo=<relay06.alfahosting-server.de>
    Aug 25 16:57:20 mail postfix/smtpd[29934]: NOQUEUE: filter: RCPT from relay06.alfahosting-server.de[109.237.XXX.XXX]: <[email protected]>: Sender address triggers FILTER amavis:[127.0.0.1]:10024; from=<[email protected]> to=<[email protected]> proto=ESMTP helo=<relay06.alfahosting-server.de>
    Aug 25 16:57:20 mail postgrey[946]: action=greylist, reason=new, client_name=relay06.alfahosting-server.de, client_address=109.237.XXX.XXX/32, [email protected], [email protected]
    Aug 25 16:57:20 mail postfix/smtpd[29934]: NOQUEUE: reject: RCPT from relay06.alfahosting-server.de[109.237.XXX.XXX]: 450 4.2.0 <[email protected]>: Recipient address rejected: Greylisted, see http://postgrey.schweikert.ch/help/example.de.html; from=<[email protected]> to=<[email protected]> proto=ESMTP helo=<relay06.alfahosting-server.de>
    Aug 25 16:57:20 mail postfix/smtpd[29934]: disconnect from relay06.alfahosting-server.de[109.237.XXX.XXX] ehlo=2 starttls=1 mail=1 rcpt=0/1 data=0/1 rset=1 quit=1 commands=6/8
     
  2. Croydon

    Croydon ISPConfig Developer ISPConfig Developer

    Please check the "mail_user" table inside the dbispconfig database and check if the mentioned user is really not greylisting-enabled.
    Secondly check that you don't have greylisting enabled globally in your main.cf of postfix (which is often the case on updated systems that had greylisting enabled before ISPConfig supported selective greylisting through the UI).
    Make sure that you do the db check on the mail server if you are on a multiserver system.
     
  3. ktownmods

    ktownmods Member

    Hey, for what i have to look in the main.cf?
     
  4. Croydon

    Croydon ISPConfig Developer ISPConfig Developer

    Uhm, for greylisting-related entries?
    As I don't know how you might have configured greylisting, I cannot answer to this more specific. Search for check_policy_service for example.
     
  5. ktownmods

    ktownmods Member

    This is in my main.cf

    Code:
    greylisting = check_policy_service inet:127.0.0.1:10023
    Code:
    smtpd_recipient_restrictions = permit_mynetworks, permit_sasl_authenticated, reject_unauth_destination, reject_rbl_client zen.spamhaus.org, check_recipient_access mysql:/etc/postfix/mysql-virtual_recipient.cf, check_recipient_access mysql:/etc/postfix/mysql-virtual_policy_greylist.cf
    
     
  6. Croydon

    Croydon ISPConfig Developer ISPConfig Developer

    That should be okay.
    Log in into your mail server's database dbispconfig and then execute:
    Code:
    SELECT 'greylisting' FROM (SELECT greylisting, source AS email FROM mail_forwarding WHERE server_id = 1 UNION SELECT greylisting, email FROM mail_user WHERE server_id = 1) addresses WHERE addresses.email='<YOURMAILADDRESS>' AND addresses.greylisting='y' UNION SELECT 'greylisting' FROM `mail_forwarding` f CROSS JOIN `mail_user` u ON u.email = f.destination WHERE f.type = 'catchall' AND u.greylisting = 'y' AND u.server_id = 1 AND f.source = '@<YOURMAILDOMAIN>'
     
  7. ktownmods

    ktownmods Member

    Sorry for answer so late, but do you mean so?

    Screenshot_468.png
     
  8. Croydon

    Croydon ISPConfig Developer ISPConfig Developer

    This means that greylisting is indeed activated for that address or for a catchall that redirects to this address.
     
  9. ktownmods

    ktownmods Member

    Hey, i have an catchall but it dont redirect to this email, so what can i do now, because in mail Settings on ispconfig greylisting is deactivated?

    Thx
     
  10. Croydon

    Croydon ISPConfig Developer ISPConfig Developer

    Then execute the queries one by one to check which setting has greylisting enabled.
    Code:
    SELECT greylisting, source AS email FROM mail_forwarding WHERE server_id = 1 AND source = '<YOURMAILADDRESS>';
    Code:
    SELECT greylisting, email FROM mail_user WHERE server_id = 1 AND email = '<YOURMAILADDRESS>';
    Code:
    SELECT u.greylisting, f.source FROM `mail_forwarding` f CROSS JOIN `mail_user` u ON u.email = f.destination WHERE f.type = 'catchall' AND u.greylisting = 'y' AND u.server_id = 1 AND f.source = '@<YOURMAILDOMAIN>';
     
  11. ktownmods

    ktownmods Member

    Hey,
    and now?

    Screenshot_472.png Screenshot_470.png Screenshot_471.png
     
  12. Croydon

    Croydon ISPConfig Developer ISPConfig Developer

    As you can see you have a catchall for your mail domain and the target of that catchall has greylisting enabled. This affects all incoming mail to that domain.

    However, this behaviour is not optimal as it does not respect differing settings for a mailbox of that domain.
     
    ktownmods likes this.
  13. Croydon

    Croydon ISPConfig Developer ISPConfig Developer

    ktownmods likes this.
  14. ktownmods

    ktownmods Member

    Thanks, but now i am a little bit confused.

    What i have to do now?
    Wait?

    Thx for your time and help
     
  15. Taleman

    Taleman Well-Known Member HowtoForge Supporter

    You can wait, of course.
    Or fix this by not using that catchall mailbox or not setting greylisting on for that catchall.
     
    Croydon likes this.

Share This Page