I'm having a problem when manually editing aliases in Virtualmin > Edit Mail Aliases.
I have an alias, email@example.com, forwarded to my address, firstname.lastname@example.org. I also have other aliases, email@example.com and firstname.lastname@example.org, which forward to email@example.com. Creating these aliases seems to work fine, at least until I click Manually Edit Aliases. The addresses that appear are rewritten as:
[code:1]test::firstname.lastname@example.org test2::test test3::test [/code:1]
If I click Save without changing anything, it states that it has in fact "Modified email alias email@example.com" and firstname.lastname@example.org, and their destinations become "test" instead of "email@example.com". This basically corrupts all the aliases-to-aliases on the domain, because "test" alone is not a valid mailbox on the server.
(If I try to send mail to firstname.lastname@example.org, it forwards this to "test", which is interpreted as "test@$mydomain", the global Postfix domain/hostname. This of course fails because no such mailbox exists.)
Is this a bug in the parsing of manually edited aliases? It seems that this function is "magical" behavior that might simplify other use cases, but in this case it renders the aliases undeliverable.