Attachments fail to download #1348

Closed
opened 2025-10-09 17:12:18 +03:00 by OVERLORD · 1 comment
Owner

Originally created by @richardluijten on GitHub.

Subject of the issue

Attachments fail to download when running vaultwarden behind a nginx TLS proxy

Deployment environment

  • vaultwarden version: Version 1.22.1
  • Install method: Docker image

  • Clients used: Android Mobile, Firefox browser pluglin, Firefox browser

  • Reverse proxy and version: nginx:1.19.4-alpine docker container

  • MySQL/MariaDB or PostgreSQL version: -

  • Other relevant details:

Steps to reproduce

Upload an attachment. Then when trying to download it from any of the clients it will fail to download

Expected behaviour

Download of the attachment

Actual behaviour

Moblie client responds with message "Failed to download". Webbrowser client failed with mixed content error.

The server logs show that the download was successfully passed to the client, however the client fails to display the content

Troubleshooting data

(German mixed-content error)
Laden von gemischten aktiven Inhalten "http:///bitwarden/attachments/84736f11-5d0a-4aaf-8e70-48caaeae709d/ed8f0a6c22a02afc64be" wurde blockiert.

ERROR Error: Uncaught (in promise): TypeError: NetworkError when attempting to fetch resource.
o/</t.fetch<@https:///app/polyfills.9ec336e5c3d7313c6a94.js:21:5431
h</e.prototype.download/</<@https:///bitwarden/app/main.9ec336e5c3d7313c6a94.js:1:1501743
s/</<@https:///bitwarden/app/main.9ec336e5c3d7313c6a94.js:1:1498275
s/<@https:///bitwarden/app/main.9ec336e5c3d7313c6a94.js:1:1498380
a@https:///bitwarden/app/main.9ec336e5c3d7313c6a94.js:1:1497094
o/</f</t.prototype.invoke@https://rllocal.duckdns.org/bitwarden/app/polyfills.9ec336e5c3d7313c6a94.js:13:7175
.........

Downloading the attachement using the link displayed in the browsers developers tools is working.

Originally created by @richardluijten on GitHub. ### Subject of the issue Attachments fail to download when running vaultwarden behind a nginx TLS proxy ### Deployment environment <!-- ========================================================================================= Preferably, use the `Generate Support String` button on the admin page's Diagnostics tab. That will auto-generate most of the info requested in this section. ========================================================================================= --> * vaultwarden version: Version 1.22.1 <!-- How the server was installed: Docker image, OS package, built from source, etc. --> * Install method: Docker image * Clients used: Android Mobile, Firefox browser pluglin, Firefox browser * Reverse proxy and version: nginx:1.19.4-alpine docker container * MySQL/MariaDB or PostgreSQL version: - * Other relevant details: ### Steps to reproduce Upload an attachment. Then when trying to download it from any of the clients it will fail to download ### Expected behaviour Download of the attachment ### Actual behaviour Moblie client responds with message "Failed to download". Webbrowser client failed with mixed content error. The server logs show that the download was successfully passed to the client, however the client fails to display the content ### Troubleshooting data (German mixed-content error) Laden von gemischten aktiven Inhalten "http://<host>/bitwarden/attachments/84736f11-5d0a-4aaf-8e70-48caaeae709d/ed8f0a6c22a02afc64be" wurde blockiert. ERROR Error: Uncaught (in promise): TypeError: NetworkError when attempting to fetch resource. o/</t.fetch<@https://<host>/app/polyfills.9ec336e5c3d7313c6a94.js:21:5431 h</e.prototype.download/</<@https://<host>/bitwarden/app/main.9ec336e5c3d7313c6a94.js:1:1501743 s/</<@https://<host>/bitwarden/app/main.9ec336e5c3d7313c6a94.js:1:1498275 s/<@https://<host>/bitwarden/app/main.9ec336e5c3d7313c6a94.js:1:1498380 a@https://<host>/bitwarden/app/main.9ec336e5c3d7313c6a94.js:1:1497094 o/</f</t.prototype.invoke@https://rllocal.duckdns.org/bitwarden/app/polyfills.9ec336e5c3d7313c6a94.js:13:7175 ......... Downloading the attachement using the link displayed in the browsers developers tools is working.
Author
Owner

@BlackDex commented on GitHub:

Your domain is probably not configured correctly: https://github.com/dani-garcia/vaultwarden/wiki/Configuration-overview#setting-the-domain-url

@BlackDex commented on GitHub: Your domain is probably not configured correctly: https://github.com/dani-garcia/vaultwarden/wiki/Configuration-overview#setting-the-domain-url
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/vaultwarden#1348