Self-hosted connection problem on a private network

Hello!

I have a TrueNas setup running Tailscale and Vaultwarden. I want to access Vaultwarden in the local network, but I’m having some issues with the Bitwarden app.

I used TrueNas to create a certificate authority and an intermediate certificate authority. I used the intermediate CA to sign the certificates, and I installed this CA on my devices.

With this setup, I can access Vaultwarden using my local IP through the browser, the extension, and the desktop client. However, the Android app doesn’t work, giving the message Exception message: Connection failure.

At first, I thought that the problem could be either:

  • Not using the 443 port (TrueNas doesn’t let me use ports lower than 9000)
  • Something wrong with the certificate
  • The app couldn’t access user-installed certificates

But I ruled out all of this hypothesis because I got the mobile app to work after temporarily port-forwarding the Vaultwarden server and using my public IP with a custom port. Honestly, at this point, I have no idea what to do to get the app working on my private network.

Thanks!

I created the certificate authorities with the same Common Name and Subject Alternative Name as the signed certificates (because I created them on the same server where is vaultwarden and used the server’s IP address for those names). I don’t know why, but this caused a trust problem on Android, and I also don’t know why it worked on the Android browsers.

To solve this problem, I created the certificate authorities using an additional network card and the corresponding new IP address for the Common Name and Subject Alternative Name.