Skip to content

Drop attachment requirements for media download#646

Merged
clokep merged 11 commits into
mainfrom
hs/add-media-inline-support
Sep 29, 2023
Merged

Drop attachment requirements for media download#646
clokep merged 11 commits into
mainfrom
hs/add-media-inline-support

Conversation

@Half-Shot
Copy link
Copy Markdown
Collaborator

@Half-Shot Half-Shot requested review from a team as code owners August 8, 2023 23:29
Copy link
Copy Markdown
Member

@erikjohnston erikjohnston left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I thought inline media still had file names?

Also, can we add a test for ensuring that a known unsafe (e.g. pdfs?) content is returned as an attachment? I know its not specced, but it is a security thing so I'd like not to lose the test. We can always mark it as synapse specific.

Comment thread tests/media_filename_test.go Outdated
Comment thread tests/media_filename_test.go Outdated
Comment thread tests/media_filename_test.go Outdated
@Half-Shot Half-Shot requested a review from kegsay as a code owner August 21, 2023 16:50
Half-Shot and others added 2 commits August 21, 2023 18:24
Co-authored-by: Erik Johnston <erik@matrix.org>
@Half-Shot Half-Shot requested a review from erikjohnston August 21, 2023 21:40
@Half-Shot
Copy link
Copy Markdown
Collaborator Author

@kegsay has been review requested because of the SVG file, but I'm unsure how much he cares to review it. Of course, more than welcome :)

Comment thread tests/media_filename_test.go
Copy link
Copy Markdown
Member

@erikjohnston erikjohnston left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Otherwise i think LGTM

Comment thread tests/media_filename_test.go Outdated
@clokep clokep requested a review from a team September 22, 2023 17:22
@clokep
Copy link
Copy Markdown
Member

clokep commented Sep 22, 2023

I updated this to handle the remaining review comments. I think this is ready for another review.

@clokep clokep merged commit e722748 into main Sep 29, 2023
@clokep clokep deleted the hs/add-media-inline-support branch September 29, 2023 11:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

TestMediaFilenames incorrectly tests Content-Disposition

5 participants