thanks for the correction Edgar, seems like expansion to virtual addresses cannot be done…
I guess I’ll have to figure some other way around this. joe > debug: smtp: SIZE in MAIL FROM command > expand: 0x2cb69128018: expand_insert() called for > address:[email protected][parent=0x0, rule=0x0] > expand: 0x2cb69128018: inserted node 0x2cb26a38800 > expand: lka_expand: address: [email protected] [depth=0] > expand: 0x2caa8647d80: expand_insert() called for > address:[email protected][parent=0x0, rule=0x0] > expand: 0x2caa8647d80: inserted node 0x2cb571ef800 > expand: 0x2cb69128018: expand_insert() called for > address:[email protected][parent=0x2cb26a38800, rule=0x2cb4239af80, > dispatcher=0x2ca8c7b2f40] > expand: 0x2cb69128018: inserted node 0x2cb571f0000 > expand: 0x2caa8647d80: clearing expand tree > expand: 0x2caa8647d80: freeing expand tree > debug: aliases_virtual_get: ’nospam' resolved to 1 nodes > expand: lka_expand: address: [email protected] [depth=1] >> expand: lka_expand: no aliases for virtual > expand: 0x2cb69128018: clearing expand tree > 5e46de4fb978d5bf smtp failed-command command="RCPT TO:<[email protected]> > ORCPT=rfc822;[email protected]" result="524 5.2.4 Mailing list expansion > problem: <[email protected]>" > 5e46de4fb978d5bf smtp disconnected reason=quit regards > On 24 Aug 2019, at 18:06, Edgar Pettijohn <[email protected]> wrote: > > On Sat, Aug 24, 2019 at 06:02:55PM +0200, Joseph A Borg wrote: >> AFAIK I can do that Edgar, I???m already filtering on domain, so the domain >> stump is not really necessary. >> >> this is not an urgent work situation, I???m just trying things out and spent >> way too much time understanding this not to bother the list. If there is a >> workaround or it???s a known issue it???s fine. Most probably I???m >> misunderstanding things. >> >> Correct me if I???m wrong: I???m assuming, conceptually, that once the >> aliases in a message's [RCPT TO list] are expanded, the new addresses go >> through the rule set again and enqueued if they match something that ends up >> in a mailbox, forwarded. At least that???s what I remember from on elf >> Gilles articles. If I???m imagining too much then I???ll try something else. >> :) >> >> I???m trying to run smtpd -F -v -T all and not getting anything on the >> command line. > > -F logs to syslogd. If you want to see it try `smtpd -dv -T all' > > Not entirely helpful, but I switched to sql tables because I couldn't figure > out a similar situation. > > Edgar > >> >> >> regards to all on a sultry Saturday evening >> >> >>> On 24 Aug 2019, at 17:43, Edgar Pettijohn <[email protected]> wrote: >>> >>> On Sat, Aug 24, 2019 at 04:14:21PM +0200, Joseph A Borg wrote: >>>> I???m trying to match an email: [email protected] to expand to >>>> [email protected] and deliver to local mailbox. >>>> >>>> My setup is pretty simple and works well for virtual mailboxes linked to a >>>> couple of virtual domains. now I???m trying t add aliases to some accounts. >>>> >>>> From the error, it seems like smtpd is not transforming the alias address >>>> into the final address for delivery. >>>> Seems like I???m not understanding how smtpd transforms an recipient >>>> address in an <alias_table> into the actual recipient for delivery. >>>> >>>> I must be conceptually stumped on this one. >>>> >>>> I get the following error in logs and a return mail from smtpd to sender: >>>> >>>>> >>>>> I'm sorry to have to inform you that your message could not >>>>> be delivered to one or more recipients. >>>>> >>>>> >>>>> <[email protected]>: host mx.domain.tld[xxx.xxx.xxx.xxx] said: 550 Invalid >>>>> recipient: <[email protected]> (in reply to RCPT TO command) >>>>> Reporting-MTA: dns; st43p00im-zteg10071901.me.com >>>>> X-Postfix-Queue-ID: 4E253D8138E >>>>> X-Postfix-Sender: rfc822; [email protected] >>>>> Arrival-Date: Sat, 24 Aug 2019 10:24:30 +0000 (UTC) >>>>> >>>>> Final-Recipient: rfc822;[email protected] >>>>> Original-Recipient: rfc822;[email protected] >>>>> Action: failed >>>>> Status: 5.0.0 >>>>> Remote-MTA: dns; mx.domain.tld >>>>> Diagnostic-Code: smtp; 550 Invalid recipient: <[email protected]> >>>>> >>>>> From: <[email protected]> >>>>> Subject: Fwd: Undelivered Mail Returned to Sender >>>>> Date: 24 August 2019 at 12:24:27 GMT+2 >>>>> To: [email protected] >>>>> >>>> >>>> >>>> >>>> the configuration files for the domain and tables follows. >>>> >>>> >>>> >>>> >>>> # file:/etc/mail/domain.tld/accounts/valiases: >>>> ================================= >>>>> nospam [email protected] >>>> ## EOF >>>> >>>> # file:/etc/mail/domain.tld/accounts/emails >>>> ================================ >>>>> [email protected] 9999:9999:/home/domain/mail/master >>>>> [email protected] 9999:9999:/home/domain/mail/duster >>>>> [email protected] 9999:9999:/home/domain/mail/buster >>> >>> I'm not sure this will work. I'm not sure you can map a virtual user to >>> a single system user with multiple `homes'. >>> >>> maybe try: >>> >>> webmaster 9999:9999:/home/domain/mail/master >>> >>> and see if that gets you further. >>> >>>> ## EOF >>>> >>>> # file:/etc/mail/domain.sub.smtpd.conf >>>> ============================= >>>> >>>>> ## ===================== >>>>> ## DOMAIN CONFIGURATION: >>>>> ## ===================== >>>>> # TABLE DECLARATIONS: >>>>> # ------------------- >>>>> table domains \ >>>>> file:/etc/mail/domain.tld/domains >>>>> table valiases \ >>>>> file:/etc/mail/domain.tld/accounts/valiases >>>>> table e-boxes \ >>>>> file:/etc/mail/domain.tld/accounts/emails >>>>> >>>>> # ACTIONS >>>>> # ------- >>>>> action valiases_set \ >>>>> expand-only \ >>> >>> Seems like expand-only should work with `virtual' aliases, but I'm not sure. >>> Maybe remove it and see what happens. >>> >>>>> virtual <valiases> >>>>> action deliver_virtual_set \ >>>>> maildir \ >>>>> userbase <e-boxes> >>>>> >>>>> # MATCHES >>>>> # ------- >>>>> match from any \ >>>>> for domain <domains> \ >>>>> action valiases_set >>>>> match from any \ >>>>> for domain <domains> \ >>>>> action deliver_virtual_set >>>>> >>>>> >>>> >>> >>> Hope this helps. >>> >>> Edgar >> >
