On Sun, Mar 16, 2014 at 9:43 AM, Noel Jones <njo...@megan.vbhcs.org> wrote:
> On 3/16/2014 8:31 AM, Rick Zeman wrote:
>> On Sat, Mar 15, 2014 at 11:34 PM, Noel Jones <njo...@megan.vbhcs.org> wrote:
>>> On 3/15/2014 5:08 PM, Rick Zeman wrote:
>>>> I've started working on my bastard Mac postfix relay.  For delivery to
>>>> the local domain, it will only relay to the internal mail server
>>>> defined in transport if the user exists locally on the postfix
>>>
>>> When relaying to an inside server, the domain should be specified in
>>> relay_domains, not mydestination.
>>>
>>> Valid recipients should be listed in relay_recipient_maps.
>>>
>>> You can override the users to be delivered locally by using a
>>> transport_maps entry pointing those users to the local: delivery
>>> transport.
>>>
>>> http://www.postfix.org/ADDRESS_CLASS_README.html
>>> http://www.postfix.org/BASIC_CONFIGURATION_README.html
>>> http://www.postfix.org/STANDARD_CONFIGURATION_README.html
>>>
>>>
>>> And turn off the debug logging -- it's rarely useful for any but the
>>> most obscure errors, and the big errors get lost in the noise.
>>>
>>
>> Oy.  Got it, thanks.  One last question.  I have recipient_delimiters
>> = - and also reject_unverified_recipient in the smtpd recipient
>> restrictions.  It looks like postfix (on my system, at least) does the
>> smtp probe to the destination before the re-write of user-foo@ to
>> user@ so it's effectively useless.  Are they mutually exclusive, or is
>> there a way to force the rewrite to happen before the probe?  I didn't
>> see anything under either common in the docs that addressed this
>> scenario.
>>
>
> Postfix does not rewrite user-...@example.com to u...@example.com.
> Rather, postfix will use "fake" lookups of u...@example.com for
> select table lookups as documented elsewhere, and carefully preserve
> the -foo extension during delivery.
>
> Recipient address verification probes are always sent using the
> exact address as supplied by the client.  If the remote system
> doesn't accept user-foo@ as a valid address then the probe will
> fail, as it should.
>
> If you need to strip the address extension, you could use
> smtp_generic_maps to remove the extension during delivery.

The reading that I just did (generic, canonical) suggests that using a
canonical table so cleanup(8) will rewrite the address before the
inbound mail is queued vs generic_maps which would rewrite after it's
queued.  Is that the only fundamental difference?  In reading both doc
pages, however, I really didn't see any examples that would remap
user-...@example.com to u...@example.com.  Nor could I find a good
example by googling.

Reply via email to