-
-
Notifications
You must be signed in to change notification settings - Fork 663
Media-links now force download instead of just showing content inline in browser #3139
Description
Background information
- Dendrite version or git SHA: 0.13.0 and above
- SQLite3 or Postgres?: N/A
- Running in Docker?: N/A
go version: N/A- Client used (if applicable): Any text-only client, and any non-matrix-client
Description
- What is the problem: Media-links now force download instead of just showing content inline in browser
- Who is affected:
- Anyone using a text-only client
- Anyone receiving a link to a matrix-attachement outside of a matrix-client (people share links to content uploaded to matrix outside of matrix).
- This would also affect anyone on the other side of a bridge where attachements are sent as plain links, i.e. the matrix-IRC-bridges.
- How is this bug manifesting: When clicking a link to an attachement, a download is forced, instead of just showing the media inline in the browser. I used to be able to just click a link and view the attachement directly in my browser.
- When did this first appear: In Fix unsafe hotserving behaviour for multimedia uploads. #3113, and released in 0.13.0
Steps to reproduce
- Try to view https://matrix.dnns.no/_matrix/media/r0/download/dnns.no/cgFcEHtGykrmYbRjbzoxOUtl
- It will present as a download
- Expected behaviour would be to just show the image in the browser
The example above is from a server running matrix-synapse, not dendrite, but the same behaviour was introduced for dendrite in #3113.
This issue basically a duplicate of matrix-org/synapse#15885, but for dendrite. I don't actually run dendrite, but this new behaviour is really irritating to deal with as someone on the other side of a matrix-bridge where people share media.
Possible solutions
@joshqou mentions only returning disposition type inline for media in the original PR for synapse (matrix-org/synapse#15680), and returning attachement for other files. That would be a super solution, but this was unfortunately lost before the PR was merged.
Another less-than-stellar solution would be to provide a way to turn off returning attachement for all files.
In the mean time, I mention a possible workaround in matrix-org/synapse#15885 which should work for anyone hosting their own dendrite-server (behind a reverse proxy) as well.