Problem with registration E-Mail

Hello Vaultwarden users,

I currently have an issue for which I can’t find a solution, so I’m trying my luck here.

I have a self-hosted Vaultwarden Docker container running version 1.36.0.

When a new user tries to create an account, they do not receive the email from the system to verify their email address and set a password. However, all other types of emails are working correctly for existing users.

The SMTP test is successful for existing users, and the informational email notifying them of a login from a new device is also delivered without any issues.

I am sending emails through my Exchange Server without SMTP authentication.

Has anyone experienced a similar issue or knows what could be causing this?

Does the Exchange Server give any errors regarding the specific connection attempt?

In similar cases I usually use a mock SMTP server to see if the attempt is made at all, e.g. you can run fake-smtp.jar on the port to see if it tries to do anything and also if the format of the email looks ok ( FakeSMTP – FakeSMTP - Dummy SMTP server for developers )

Update / Root Cause

I finally found the root cause of the issue, so I wanted to share it in case it helps someone else.

This is a hybrid Exchange environment (Exchange On-Premises + Exchange Online). SMTP submission from Vaultwarden to the on-prem Exchange server was working correctly.

The SMTP logs showed:

  • MAIL FROM → OK

  • RCPT TO → OK

  • 250 2.6.0 Queued mail for delivery

Exchange Message Tracking also confirmed:

  • RECEIVE

  • RESOLVE

  • SENDEXTERNAL

  • RecipientStatus: 250 Accepted

One thing that initially confused me was that I could see these messages on our firewall as outgoing mail. Normally, almost no mail is sent through the firewall because our mail flow is handled differently. That made me suspect that the routing was already wrong before the message reached Exchange Online.

The actual problem turned out to be the Remote Routing Address (targetAddress) on the affected AD user objects.

It was configured as:

user@tenant.onmicrosoft.com

instead of the correct value:

user@tenant.mail.onmicrosoft.com

Because of this, Exchange resolved the recipient to the wrong remote address and routed the message incorrectly. As a result, the message never appeared in the Exchange Online Message Trace.

After correcting the targetAddress (Remote Routing Address) to user@tenant.mail.onmicrosoft.com, mail routing worked correctly and the messages were delivered successfully.

Thanks to everyone who helped point me in the right direction!

1 Like