Incoming email rejected by YunoHost

What type of hardware are you using: VPS bought online
What YunoHost version are you running: 12.1.39
How are you able to access your server: SSH

Describe your issue

https://belin.land is connected to my YunoHost server (no connected apps). Nevertheless, every email I send to tommi@belin.land is rejected… Why could this be?

Share relevant logs or error messages

Undelivered email report

Hey @tommi :waving_hand:

The error message is quite explicit:

550 5.1.1 <tommi@belin.land>: Recipient address rejected: User unknown in virtual mailbox table

This means your server does receive the email (DNS/MX are working fine), but Postfix rejects it because no mailbox exists for tommi@belin.land in the LDAP directory.

In YunoHost, simply adding a domain to your server doesn’t automatically create any email address on it. Each user gets an email address in the format username@domain.tld upon creation, and additional email aliases can be configured for each user.

So you have two options:

  1. Add tommi@belin.land as an email alias to an existing YunoHost user: go to Webadmin → Users → [your user] → Manage email aliases, and add tommi@belin.land.

  2. Create a new YunoHost user with belin.land as the primary domain, if you’d rather have a dedicated account.

Either way, once the address is registered in YunoHost’s LDAP, Postfix will accept incoming mail for it.

1 Like

Hello,

Moreover, your IPv6 points to a different host, or your Postfix SMTP server is not configured to listen to your IPv6 interface.

nc: connect to belin.land (2a02:c206:2111:134::1) port 25 (tcp) failed: Connection refused

2 Likes

Thank you so much, @djez!

I did not think about creating an alias because IMAP configuration for tommi@belin.land worked in Thunderbird even before creating it… :thinking:

Nevertheless, I now created an alias but it looks like the email is still rejected :cry:

Rejection email


About IPv6, instead, it’s Contabo going crazy sometimes… Not too reliable from this point of view. It should be working, now? :eyes:

Good news: the alias is working! The error has changed, which means the first issue is resolved.

Now, the new error is different:

553 5.7.1 <surfing@tommi.space>: Sender address rejected: not logged in

This happens because tommi.space is also a domain on your YunoHost server. When Proton Mail delivers an email from surfing@tommi.space to your server, Postfix sees the sender address belongs to a local domain but the connection is not authenticated — so it rejects it as a potential impersonation attempt.

This is caused by the reject_sender_login_mismatch directive in Postfix’s configuration.

You have two options:

  1. Quick test: try sending your test email from an address that is not on a domain hosted by your YunoHost (e.g. a Gmail address :face_vomiting:). That should go through fine and confirm the alias works.

  2. Permanent fix: if you actually need to receive emails sent from @tommi.space via Proton Mail, you can comment out reject_sender_login_mismatch in /etc/postfix/main.cf and reload Postfix (systemctl reload postfix). SPF, DKIM and DMARC already protect against sender spoofing, so the security impact is minimal. Note that YunoHost may restore this line on regen-conf postfix, so keep that in mind.

This exact issue was discussed and solved here: Question Postfix -- 553 5.7.1 ... : Sender address rejected: not logged in

2 Likes

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.