Narzędzia użytkownika

Narzędzia witryny


poczta

Różnice

Różnice między wybraną wersją a wersją aktualną.

Odnośnik do tego porównania

Poprzednia rewizja po obu stronachPoprzednia wersja
Nowa wersja
Poprzednia wersja
Nowa wersjaNastępna rewizja po obu stronach
poczta [2021/03/19 12:06] – [Przydatne narzędzia] kamilpoczta [2021/10/24 19:41] – [Postfix] kamil
Linia 336: Linia 336:
 inet_interfaces = all inet_interfaces = all
 inet_protocols = all inet_protocols = all
 +
 +smtpd_sender_login_maps = mysql:/etc/postfix/mysql-virtual-sender-login-maps.cf
  
 smtpd_recipient_restrictions = check_policy_service inet:127.0.0.1:12340, smtpd_recipient_restrictions = check_policy_service inet:127.0.0.1:12340,
Linia 474: Linia 476:
 dbname = postfix dbname = postfix
 query = SELECT CONCAT(access, IF(reason != '', CONCAT(' ', reason), '')) AS address FROM virtual_black_white_list WHERE source='%s' AND type = 'EMAIL' query = SELECT CONCAT(access, IF(reason != '', CONCAT(' ', reason), '')) AS address FROM virtual_black_white_list WHERE source='%s' AND type = 'EMAIL'
 +</file>
 +
 +Tworzymy plik /etc/postfix/mysql-virtual-sender-login-maps.cf i uzupełniamy:
 +<file>
 +user = postfix
 +password = tajnehaslo
 +hosts = 127.0.0.1
 +dbname = postfix
 +query = SELECT email FROM virtual_users WHERE email = '%s' UNION SELECT destination FROM virtual_aliases WHERE source = '%s'
 </file> </file>
  
Linia 952: Linia 963:
 $config['smtp_server'] = 'domain.ltd'; $config['smtp_server'] = 'domain.ltd';
 $config['smtp_port'] = 25; $config['smtp_port'] = 25;
-$config['smtp_user'] = ''; +$config['smtp_user'] = '%u'; 
-$config['smtp_pass'] = '';+$config['smtp_pass'] = '%p'; 
 +$config['smtp_auth_type'] = 'LOGIN';
 ... ...
 $config['plugins'] = array('managesieve'); $config['plugins'] = array('managesieve');
Linia 1152: Linia 1164:
  
 ==== Przydatne narzędzia ==== ==== Przydatne narzędzia ====
 +
 +  * postqueue
 +<file>
 +# postqueue -p
 +-Queue ID-  --Size-- ----Arrival Time---- -Sender/Recipient-------
 +56008207DE   195074 Mon Mar 22 09:28:19  user@domain.ltd
 +                   (connect to falsedomain.ltd[1.2.3.4]:25: Connection refused)
 +                                         user44@falsedomain.ltd
 +
 +-- 190 Kbytes in 1 Request.
 +</file>
 +
 +  * postsuper
 +<file>
 +# postsuper -d 56008207DE
 +postsuper: 56008207DE: removed
 +postsuper: Deleted: 1 message
 +</file>
  
   * przenoszenie skrzynek pocztowych via IMAP: [[https://github.com/imapsync/imapsync]]   * przenoszenie skrzynek pocztowych via IMAP: [[https://github.com/imapsync/imapsync]]
poczta.txt · ostatnio zmienione: 2023/12/18 12:53 przez kamil