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

Binary files are being stored as text/plain; files being uploaded that aren't in "accept" list #533

Open
winzig opened this issue Sep 21, 2023 · 3 comments

Comments

@winzig
Copy link

winzig commented Sep 21, 2023

We recently changed from using this SDK:

https://static.filestackapi.com/v3/filestack.js

to this one:

https://static.filestackapi.com/filestack-js/3.x.x/filestack.min.js

Since making this change, all binary files being uploaded to us via FS are being stored as text/plain. (Back with v3 they were coming in correctly as application/octet-stream.)

In addition, we've had users be able to upload files that are not in our accept list (e.g. a user uploaded a .dat file even though .dat is not in our accept list).

This is the configuration we're now using since switching to 3.x.x:

var fileUploader = filestack.init(FilestackApiKey);
fileUploader.picker
(
    {
        maxFiles: 50,
        globalDropZone: true,
        maxSize: 4294967000,
        videoResolution: '1280x720', // for video record live via webcam
        accept: 
        [
            "application/ai",
            "application/illustrator",
            "application/msword",
            "application/pdf",
            "application/photoshop",
            "application/postscript",
            "application/psd",
            "application/vnd.ms-powerpoint",
            "application/vnd.oasis.opendocument.presentation",
            "application/vnd.oasis.opendocument.spreadsheet",
            "application/vnd.oasis.opendocument.text",
            "application/vnd.openxmlformats",
            "application/vnd.openxmlformats-officedocument.presentationml.presentation",
            "application/vnd.openxmlformats-officedocument.presentationml.slideshow",
            "application/vnd.openxmlformats-officedocument.presentationml.template",
            "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet",
            "application/vnd.openxmlformats-officedocument.spreadsheetml.template",
            "application/vnd.openxmlformats-officedocument.wordprocessingml.document",
            "application/vnd.openxmlformats-officedocument.wordprocessingml.template",
            "application/x-illustrator",
            "application/x-photoshop",
            "image/bmp",
            "image/gif",
            "image/illustrator",
            "image/jpeg",
            "image/jpg",
            "image/photoshop",
            "image/pjpeg",
            "image/png",
            "image/psd",
            "image/svg",
            "image/svg+xml",
            "image/tiff",
            "image/vnd.adobe.illustrator",
            "image/vnd.adobe.photoshop",
            "image/webp",
            "image/x-illustrator",
            "image/x-photoshop",
            "text/html",
            "text/markdown",
            "text/pdf",
            "text/richtext",
            "text/rtf",
            "video/*",
            ".3gp",
            ".aes",
            ".ai",
            ".avi",
            ".bin",
            ".bmp",
            ".csv",
            ".doc",
            ".docx",
            ".gif",
            ".hpl",
            ".hpt",
            ".Icm",
            ".isc",
            ".ism",
            ".isp",
            ".iss",
            ".jpeg",
            ".jpg",
            ".lsc",
            ".lsm",
            ".lsp",
            ".lss",
            ".m4p",
            ".m4v",
            ".mkv",
            ".mmm",
            ".mmp",
            ".mms",
            ".mov",
            ".mp2",
            ".mp4",
            ".mpe",
            ".mpeg",
            ".mpg",
            ".mpv",
            ".mwf",
            ".odp",
            ".odt",
            ".ogg",
            ".pddata",
            ".pdf",
            ".pids",
            ".png",
            ".ppt",
            ".pptx",
            ".psd",
            ".psdata",
            ".qt",
            ".scm",
            ".scp",
            ".scs",
            ".spm",
            ".sur",
            ".svg",
            ".tdms",
            ".tif",
            ".tiff",
            ".tst",
            ".txt",
            ".vsc",
            ".vsm",
            ".vss",
            ".webm",
            ".webp",
            ".wmv",
            ".xls",
            ".xlsx",
            ".xml",
            ".zip"
        ],
        fromSources: ["local_file_system","webcam","video","facebook","dropbox","googledrive","gmail"],
        storeTo: 
        {
            location: 's3',
            path: 'raw/',
        },
        uploadConfig: 
        {
            intelligent: true
        },
        onUploadDone: function(response) 
        {
            compose.HandleFiles(response, $form);
        }
    }    
).open()

The .tdms file inside this .zip file is an example of one that exhibits the issue. (It's a binary data file from an automotive scan tool.)

test.tdms.zip

I opened a ticket directly with FS support 2 months ago, despite the support person indicating "I have replicated the issue" and passing it on to "DevOps", nothing has been done to resolve this for 2 months now.

I would go back to the v3, but then Google Drive support in the picker breaks.

Anyone here have working binary file uploads?

Expected Behavior

  1. Binary files should come in and be stored as application/octet-stream, not text/plain
  2. File types not found in accept should be prevented from being uploaded.

Current Behavior

  1. Binary files come in as text/plain
  2. File types not found in accept are being allowed
@winzig
Copy link
Author

winzig commented Dec 12, 2023

Bug is now 5 months old (reported it to FileStack in July), with no word from the company about timing of a fix. Really sad

@winzig
Copy link
Author

winzig commented Dec 12, 2023

@pcholuj @velveteer How can we get this issue resolved? Or at least some ETA on when it's likely to be fixed?

@winzig
Copy link
Author

winzig commented Dec 12, 2023

Ahh, now I see the problem:

Filestack, which was acquired by Idera, Inc. in 2022 is now wholly owned by private equity firms.

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

No branches or pull requests

1 participant