Einzelne E-Mail Adresse sperren

  • Hallo zusammen,


    kann man über die GUI anstatt eine komplette Domain, nur Einzeller E-Mail Adressen sperren?


    Falls nicht, reicht es dann, wenn man die E-Mail Adresse unter

    Code
    1. /etc/postfix/imscp/mailbox


    entfernt oder muss man das auch in

    Code
    1. /etc/postfix/imscp/aliases


    tun?


    Dass die dann neu in .db konvertiert werden müssen, ist mir klar.


    Ich bin nur nicht so ganz mit der Struktur von imscp vertraut.


    Grund: Ich möchte eine E-Mail Adresse nur temporär für ein paar Tage deaktivieren und dann wieder aktivieren. So, dass sich der User nicht mehr anmelden kann. E-Mails sollen aber trotzdem ankommen.


    Danke.

    Edited 2 times, last by Mutschas: Weiter Infos ().

  • @Mutschas


    You want just prevent the user to access IMAP/POP servers or even SMTP server? Also, does the inbound mails must still be accepted for that user or not?

    badge.php?id=1239063037&bid=2518&key=1747635596&format=png&z=547451206

  • POP3+IMAP+SMTP blocking temporary for some days.
    Ingoing Mails should be accepted, so if the block-time is over, the user don't loose any mails. But the user should not be able to login within the block-time
    Outgoing Mails should not be accepted.


    I found in the mail_users table the column "po_active". Is this the identifier for active or inactive mailaccount?

  • I found in the mail_users table the column "po_active". Is this the identifier for active or inactive mailaccount?

    Yes, because SASL auth (SMTP) is done through Dovecot SASL or Courier-authendaemon (depending on the PO server in use). Thus, if you set that column to no, the user won't be able to connect to IMAP/POP3 servers nor to SMTP server. However, inbound mails will be still accepted ;) That exactly what you want. Don't forget to reload Dovecot after changing the parameter because results are cached if I remember well.

    badge.php?id=1239063037&bid=2518&key=1747635596&format=png&z=547451206

  • @Mutschas


    Thank you! But there is no option in the Panel, right?

    There is no option do disable a mail account without deactivating other modules (http, ftp...). There is an option to fully disable a customer account in which case the po_active column of all its mail accounts is set to no. When disabling a customer account, mail accounts can be suspended in hard way or soft way:

    • Soft: The customer cannot connect to IMAP/POP3 and SMTP servers but mail account entries are not removed from the Postfix tables.
    • Hard: The customer cannot connect to IMAP/POP3 and SMTP servers and the mail account entries in the Postfix tables are removed, meaning that inbound mail will be rejected.

    Note that there is a bug for the soft mode. The domain entry is always removed from postfix table, meaning that inbound mails are always rejected.


    The suspend mode can be configured through the administrator settings interface.


    So, your choice atm is only one: Set the po_active entry manually in database to no

    badge.php?id=1239063037&bid=2518&key=1747635596&format=png&z=547451206

  • Thank you, that's ok atm.
    Anything else about the SASL output?
    Is it a Loglevel issue?


    I've found "log_level = 2" in /etc/postfix/sasl/smtpd.conf
    Is there any doc about the outputs of the log-levels?


    Good night, thanks.

  • @Mutschas


    Anything else about the SASL output?
    Is it a Loglevel issue?

    There is no issue but hey, I know a friend that you also know: Google ;)


    https://groups.google.com/foru…postfix.users/w32psGKwG9Y


    If you use Dovecot:


    In your /etc/dovecot/dovecot.conf file, you must add

    Code
    1. protocol smtp {auth_verbose = yes}

    And then restart dovecot: service dovecot restart


    Result after login failure (SMTP SASL)


    Code
    1. Apr 28 00:23:58 www postfix/smtpd[17430]: warning: unknown[192.168.1.1]: SASL PLAIN authentication failed:
    2. Apr 28 00:24:02 www dovecot: auth-worker(17426): sql([email protected],192.168.1.1): unknown user

    The second line will show you the user.

    badge.php?id=1239063037&bid=2518&key=1747635596&format=png&z=547451206