Rocket.Chat icon indicating copy to clipboard operation
Rocket.Chat copied to clipboard

Default accepted file uploads

Open aaronhagopian opened this issue 10 years ago • 19 comments

Running the latest docker image, I cannot upload Excel or CSV files. Not sure why the system is setup to reject any mime types (unless there is some security thoughts i'm missing).

I noticed an older issue where restarting fixed for them but i have restarted and the issue has not gone away.

aaronhagopian avatar Feb 02 '16 03:02 aaronhagopian

Figured it out but seems like not sane defaults for people new to rocketchat. I suggest instead changing this issue to address common file types to be allowed by default like excel, zip etc.

aaronhagopian avatar Feb 02 '16 04:02 aaronhagopian

Status on this issue?

twhiting avatar Mar 11 '16 22:03 twhiting

What do you guys suggest for the default value?

engelgabriel avatar Mar 11 '16 22:03 engelgabriel

The reason I bring this up is we cannot upload .zip files even when the setting is specifically set to allow all types of uploads. This was marked as an improvement a month ago and seemed to be a dead issue. Thanks for adding it to the milestone @engelgabriel

Ideally, I think that when all types of uploads are allowed that should be taken literally to allow all types. Including ZIP / CSV / EXCEl etc. Then a separate toggle switch could be made to limit some hazardous file types if desired.

Edit: a field to list accepted ( or all ) filetypes and another to specify dis-allowed filetypes. This might be the best solution

twhiting avatar Mar 11 '16 22:03 twhiting

@twhiting do you mean the Accepted Media Types?

image

engelgabriel avatar Mar 11 '16 22:03 engelgabriel

Yes, as stated if I "Leave it blank for accepting all media types" I still cannot upload a zip file. Is this by design?

twhiting avatar Mar 11 '16 22:03 twhiting

Did you try restarting the server after changing the setting?

engelgabriel avatar Mar 11 '16 22:03 engelgabriel

Yes

twhiting avatar Mar 11 '16 22:03 twhiting

To add to this issue. I currently have my file upload set to (since leaving it blank doesn't work):

image/*,audio/*,application/*,text/*,video/*,*/*

And I still cannot upload file types such as: .sys .dmp .LOG .inf

twhiting avatar Mar 18 '16 17:03 twhiting

You can now leave it blank or just put a single "*" as on the settings to allow all. This should be fixed on version 0.23.0 Please reopen otherwise.

engelgabriel avatar Mar 22 '16 12:03 engelgabriel

This should really be explained better in the UI. Especially since there now seem to be two kinds of "all". Empty means some ill-defined subset of all while * means really-yes-I-want-all.

ulope avatar Mar 23 '16 11:03 ulope

Strange, that shouldn't be the case. Empty and * should be the same.

@sampaiodiego can you investigate this?

engelgabriel avatar Mar 23 '16 15:03 engelgabriel

For CSV file add text/csv or my configuration image/*,audio/*,application/zip,application/pdf,text/plain, text/csv,application/ms-powerpoint,application/msword,application/ms-excel,application/vnd.openxmlformats-officedocument.wordprocessingml.document,application/vnd.openxmlformats-officedocument.spreadsheetml.sheet,application/vnd.openxmlformats-officedocument.presentationml.presentation Word(.doc & docx) Excel(.xls & xls) Powerpoint(.ppt & .pptx)

souhaib22 avatar Sep 28 '16 15:09 souhaib22

Would be great to include Open Document formats by default, too... application/vnd.oasis.opendocument.*

lightweight avatar Dec 13 '17 23:12 lightweight

I note that manually specifying application/vnd.oasis.opendocument.* (and restarting the server) does not seem to successfully allow application/vnd.oasis.opendocument.text- am I misunderstanding how "*" (wildcards) work? I'm on 0.59.4

lightweight avatar Dec 13 '17 23:12 lightweight

if you have a popup saying that text/csv not allowed.. add it to access media types with comma at the end of the line ",text/csv"

relorsulgan avatar May 04 '18 12:05 relorsulgan

I'm not able to allow upload of .plist files. I've tried adding plist, .plist, *.plist, */plist and application/x-plist. The only way I could find out was leaving the whole field blank.

igor9silva avatar May 30 '18 14:05 igor9silva

@igor9silva Have you tried application/xml or application/octet-stream?

vynmera avatar May 30 '18 14:05 vynmera

@vynmera application/xml was already there. I've just tried application/octet-stream which failed as well.

igor9silva avatar May 30 '18 14:05 igor9silva