Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[FIX] Allow unknown file types if no allowed whitelist has been set (#7074) #8172

Merged
merged 1 commit into from
Sep 18, 2017

Conversation

TriPhoenix
Copy link
Contributor

@RocketChat/core

Closes #7074

This moves the type validity check down to fileUploadIsValidContentType(). This way the whitelist can be checked first, before denying uploads of unknown file types. This way unknown/undetected file types are allowed, if and only if the whitelist is completely empty.

Copy link
Contributor

@Lawri-van-Buel Lawri-van-Buel left a comment

Choose a reason for hiding this comment

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

Seems good to me, and should fix the issues with file upload.

@rodrigok rodrigok added this to the 0.59.0-rc.6 milestone Sep 18, 2017
@rodrigok rodrigok merged commit 3005434 into RocketChat:develop Sep 18, 2017
rodrigok added a commit that referenced this pull request Sep 18, 2017
[FIX] Allow unknown file types if no allowed whitelist has been set (#7074)
@TriPhoenix TriPhoenix deleted the file-upload-allow-whitelist branch September 19, 2017 08:01
@b4ps
Copy link

b4ps commented Aug 3, 2020

still cannot add custom file extensions to the whitelist, or did i miss something?

@sprietNathanael
Copy link

It seems files without mime-types still can not be uploaded. Is there a way to make it work?

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.

How can I upload .msg file in Rocket.Chat
5 participants