esackbauer
I agree.
Would you happen to know how to enable verbose debug level for postfix?
Ideally to log every SMTP command.
I have just figured the verbose logging out.
Take a look at this exchange between my mailcow server and outlook’s.
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: > mail-db5eur02on2091.outbound.protection.outlook.com[40.107.249.91]: 220 mail.mydomain.cz ESMTP Postcow
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: watchdog_pat: 0x55de708c3360
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: vstream_fflush_some: fd 11 flush 38
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: vstream_buf_get_ready: fd 11 got 52
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: < mail-db5eur02on2091.outbound.protection.outlook.com[40.107.249.91]: EHLO EUR02-DB5-obe.outbound.protection.outlook.com
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: report helo to all milters
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: milter_macro_lookup: "{tls_version}"
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: milter_macro_lookup: "{cipher}"
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: milter_macro_lookup: "{cipher_bits}"
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: milter_macro_lookup: "{cert_subject}"
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: milter_macro_lookup: "{cert_issuer}"
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: milter8_helo_event: milter inet:rspamd:9900: helo EUR02-DB5-obe.outbound.protection.outlook.com
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: event: SMFIC_HELO; macros: (none)
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: skipping reply for event SMFIC_HELO from milter inet:rspamd:9900
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: match_list_match: mail-db5eur02on2091.outbound.protection.outlook.com: no match
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: match_list_match: 40.107.249.91: no match
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: > mail-db5eur02on2091.outbound.protection.outlook.com[40.107.249.91]: 250-mail.zsmszdarky.cz
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: > mail-db5eur02on2091.outbound.protection.outlook.com[40.107.249.91]: 250-PIPELINING
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: > mail-db5eur02on2091.outbound.protection.outlook.com[40.107.249.91]: 250-SIZE 104857600
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: > mail-db5eur02on2091.outbound.protection.outlook.com[40.107.249.91]: 250-ETRN
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: > mail-db5eur02on2091.outbound.protection.outlook.com[40.107.249.91]: 250-STARTTLS
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: > mail-db5eur02on2091.outbound.protection.outlook.com[40.107.249.91]: 250-ENHANCEDSTATUSCODES
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: > mail-db5eur02on2091.outbound.protection.outlook.com[40.107.249.91]: 250-8BITMIME
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: > mail-db5eur02on2091.outbound.protection.outlook.com[40.107.249.91]: 250-DSN
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: > mail-db5eur02on2091.outbound.protection.outlook.com[40.107.249.91]: 250 CHUNKING
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: watchdog_pat: 0x55de708c3360
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: vstream_fflush_some: fd 11 flush 146
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: vstream_buf_get_ready: fd 11 got 10
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: < mail-db5eur02on2091.outbound.protection.outlook.com[40.107.249.91]: STARTTLS
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: query milter states for other event
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: milter8_other_event: milter inet:rspamd:9900
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: > mail-db5eur02on2091.outbound.protection.outlook.com[40.107.249.91]: 220 2.0.0 Ready to start TLS
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: vstream_fflush_some: fd 11 flush 30
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: abort all milters
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: milter8_abort: abort milter inet:rspamd:9900
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: auto_clnt_open: connected to private/tlsmgr
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: event_enable_read: fd 19
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: event_request_timer: set 0x7f70934968a0 0x55de7089c240 5
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: event_request_timer: set 0x7f70934968c0 0x55de7089c240 1000
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: send attr request = seed
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: send attr size = 32
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: vstream_fflush_some: fd 19 flush 22
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: vstream_buf_get_ready: fd 19 got 60
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: private/tlsmgr: wanted attribute: status
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: input attribute name: status
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: input attribute value: 0
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: private/tlsmgr: wanted attribute: seed
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: input attribute name: seed
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: input attribute value: 4QYX9lyV+wG9mUCTF9BqBiYpbJwNSGQe48MvpNxqU0A=
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: private/tlsmgr: wanted attribute: (list terminator)
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: input attribute name: (end)
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: maps_file_find: tls_server_sni_maps: hash:/opt/postfix/conf/sni.map(0,lock|fold_fix|src_rhs_is_file): mail.mydomain.cz = LS0tLS1CRUdJTiBQUklWQVRFIEtFWS0tLS0tCk1JSUpRZ0lCQURBTkJna3Foa2lHOXcwQkFRRUZBQVNDQ1N3d2dna29BZ0VBQW9J...
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: Anonymous TLS connection established from mail-db5eur02on2091.outbound.protection.outlook.com[40.107.249.91] to mail.zsmszdarky.cz: TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: watchdog_pat: 0x55de708c3360
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: vstream_buf_get_ready: fd 11 got 6
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: < mail-db5eur02on2091.outbound.protection.outlook.com[40.107.249.91]: QUIT
Jan 7 11:59:12 82951a3ee468 postfix/smtpd[395]: > mail-db5eur02on2091.outbound.protection.outlook.com[40.107.249.91]: 221 2.0.0 Bye