Documentation on how to prevent anyone from uploading files
See original GitHub issueThis may be already solved, or considered trivial by more experienced people, but I just want to host documentation for a project of mine.
If I now host my Docat website and link to a project, any user could click the home icon: and then upload anything, since that does not require a token of any sort, if the version name is different: besides this being a possible security risk I also don’t want anyone to be able to upload files.
Otherwise, anyone would also be able to upload files using curl:
curl -X POST -F "file=@malicious-archive.zip" http://localhost:8000/api/existing-project/none-existing-version
Either there is some obvious difference between my localhost website and a public one, but if anyone can also upload files from anywhere, I think this should be solved?
Issue Analytics
- State:
- Created a year ago
- Comments:6 (2 by maintainers)
Top Results From Across the Web
File Upload Protection – 10 Best Practices for Preventing ...
How to Prevent File Upload Attacks · 1. Only allow specific file types. · 2. Verify file types. · 3. Scan for malware....
Read more >A guide to secure file uploads: how to make your website ...
A list of best practices that help you secure your file upload service and prevent your website from the most common upload-related attacks....
Read more >How do I prevent users from uploading documents?
A possible solution could be: Create a new document library. Create a new permission level by copying an existing level.
Read more >Secure File Upload Best Practices: Blocking Malicious ...
Does your website allow users to upload files? Learn secure file upload best practices and prevent dangerous vulnerabilities and attacks.
Read more >File Upload Cheat Sheet
Although it should not be relied upon for security, it provides a quick check to prevent users from unintentionally uploading files with the...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I recommend you use Authelia or something similar to easily manage access.
This is not really in the project scop imho.
@feefladder you where on the right track but there is not really a need to build your own container. There preferred solution to this problem is to host the docker container behind a reverse proxy where you can implement basic auth or what ever else of restrictions you want to have.
And the other option is to override and adjust the NGINX config inside the docker container. I documented both in the wiki for future use: https://github.com/docat-org/docat/wiki/HTTP-Basic-Auth