Skip to content

Commit

Permalink
Merge pull request #185 from whyscream/respectful-logging
Browse files Browse the repository at this point in the history
Allow parsing of postscreen actions when `respectful_logging=yes`
  • Loading branch information
whyscream authored Jan 24, 2024
2 parents d0ae57c + bf55b32 commit 1588888
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
2 changes: 1 addition & 1 deletion postfix.grok
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ POSTFIX_ACTION (accept|defer|discard|filter|header-redirect|reject|reject_warnin
POSTFIX_STATUS_CODE \d{3}
POSTFIX_STATUS_CODE_ENHANCED \d\.\d+\.\d+
POSTFIX_DNSBL_MESSAGE Service unavailable; .* \[%{GREEDYDATA:postfix_status_data}\] %{GREEDYDATA:postfix_status_message};
POSTFIX_PS_ACCESS_ACTION (DISCONNECT|BLACKLISTED|WHITELISTED|WHITELIST VETO|PASS NEW|PASS OLD)
POSTFIX_PS_ACCESS_ACTION (DISCONNECT|DENYLISTED|BLACKLISTED|ALLOWLISTED|WHITELISTED|ALLOWLIST VETO|WHITELIST VETO|PASS NEW|PASS OLD)
POSTFIX_PS_VIOLATION (BARE NEWLINE|COMMAND (TIME|COUNT|LENGTH) LIMIT|COMMAND PIPELINING|DNSBL|HANGUP|NON-SMTP COMMAND|PREGREET)
POSTFIX_TIME_UNIT %{NUMBER}[smhd]
POSTFIX_KEYVALUE_DATA [\w-]+=[^;]*
Expand Down
6 changes: 6 additions & 0 deletions test/postscreen_0030.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
pattern: ^%{POSTFIX_POSTSCREEN}$
data: "ALLOWLIST VETO [61.238.241.86]:53024"
results:
postfix_postscreen_access: ALLOWLIST VETO
postfix_client_ip: 61.238.241.86
postfix_client_port: 53024

0 comments on commit 1588888

Please sign in to comment.