<pattern-list>set by the Hub
It matches the envelope return address: the one the sender named in the SMTP MAIL FROM command and to which bounces will return. The manual specifically notes that this is not the From header the recipient sees in a mail program. The difference is significant: the sender is free to write any header, while the envelope is set at submission.
The rule’s form is the directive name, a pattern in slashes and a result: virtual-mta=name, recipient-priority=N or call-to: with the name of another list. Results can be combined with commas.
The regular expressions are in the Perl dialect, and by default they are case-insensitive. Case sensitivity can be restored with the (?-i) modifier inside the pattern.
The Hub rewrites the return address to bounce@bounce.<domain>, but the rules match the original one: verified on a node on Sep 15, 2026 — messages submitted with the shared login went through the streams of their own domains, although accounting already showed the rewritten address.
How to write the pattern. Three things decide almost everything:
| Technique | Why |
|---|---|
| escape dots — \. | otherwise a dot means any character |
| put a $ anchor at the end of the domain | otherwise a decoy subdomain will match |
| match the domain, not the local part | the local part changes, the domain does not |
Rule order. The first match wins, so narrow patterns go above broad ones. A rule added below a broad one that already matches will never fire.
# one rule per sending domain — this is how the Hub builds the list <pattern-list mta-hub-senders> mail-from /@shop\.example\.com$/ virtual-mta=shop-example-com mail-from /@news\.example\.com$/ virtual-mta=news-example-com </pattern-list>
what people get wrong and how it ends3 mistakes▶
§ 3.3.14.2
§ 3.3.14
§ 9.4.2
2 relations
pattern-list<source>The rule works only if the list is plugged into a source. § 3.3.7.42
pmtaacctfind --output csv[orig,vmta,rcpt] /var/log/pmta/acct-*.csv | head -30
3 articles
◇Headers the sender uses to control deliverySix control headers let the submitting side choose a stream, tag a message with a job, set signing options and the key, the envelope identifier and the schedule; each is allowed separately and per source.◇Selecting a sending address by message contentRegular expressions are matched against a header, the return address or the recipient and select a sending address or assign a priority; lists can call each other.◇How a message gets into the engineSix described submission methods: extended SMTP, four language bindings and a directory the node watches on disk.