Prevent exe file upload to website

Can someone tell me how to prevent the exe file from being uploaded to the website even if the exe file is inside the zip file (the exe file is in a new folder and the new folder is then zipped and downloaded)?

+3
source share
2 answers

Allow users to download the file (if it is ZIP) and perform server-side verification by unpacking the archive and evaluating its contents.

+2
source

Short answer: you cannot. Pedantic answer: do not upload files to users.

: ? ? . , , .

: - -.
- ASP.NET , - , , .
- Shell.Execute . Duh.

? .

+1

Source: https://habr.com/ru/post/1744898/


All Articles