Don't allow upload .exe files

Please post here if you have problems in using Wing FTP Server.
Post Reply
albertorodriguez
Posts: 1
Joined: Tue Nov 18, 2025 11:11 pm

Don't allow upload .exe files

Post by albertorodriguez »

Good morning

Is there any way to stop upload exe files?

Thank you
FTP
Site Admin
Posts: 2158
Joined: Tue Sep 29, 2009 6:09 am

Re: Don't allow upload .exe files

Post by FTP »

You may add a Deny Rule "*.exe" under "Domain > Settings > IP Access", but it will block both upload and download.

So you can also try the following Lua script in the event "Domain > Event Manager > BeforeFileUploaded":

Code: Select all

local filepath = string.gsub("%PathName", "\\","/")
local ext = string.lower(string.sub(filepath,-4))

if ext == ".exe" then
    bCancelEvent = true
end
Post Reply