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

Reject invalid uploads to SPIFFS via manual updates #98

Closed
doudar opened this issue Feb 18, 2021 · 3 comments
Closed

Reject invalid uploads to SPIFFS via manual updates #98

doudar opened this issue Feb 18, 2021 · 3 comments
Labels
enhancement New feature or request help wanted Extra attention is needed

Comments

@doudar
Copy link
Owner

doudar commented Feb 18, 2021

We need to validate manually uploaded files to determine if they are valid for use instead of blindly dumping them into spiffs if they are not named firmware.bin

Additional checks could be:

  • Only accept firmware.bin or HTML files.
  • Check the free space in SPIFFS and don't accept anything that is too big.
  • Probably more......

The code to process this starts at:

/*handling uploading firmware file */

@doudar doudar added enhancement New feature or request help wanted Extra attention is needed labels Feb 18, 2021
@MarkusSchneider
Copy link
Collaborator

With PR #294 the upload dialog has a file mask (*.bin, *.html). Mask should prevent upload of wrong files like firmeware.elf, ...
There is no server side validation of the file or check of free space.
File mask is an easy fix that should help user to pick the right files.

@doudar
Copy link
Owner Author

doudar commented Jan 1, 2022

That sounds like a great solution. Thanks Markus!

@doudar
Copy link
Owner Author

doudar commented Jan 28, 2022

Fixed & merged.

@doudar doudar closed this as completed Jan 28, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

2 participants