Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function checkFileForVirus(filePath)
- local old_sleep = _G["sleep"]
- _G["sleep"] = function()
- end
- local environment = {
- ["os"] = {},
- ["io"] = {},
- ["shell"] = {},
- ["term"] = term,
- ["fs"] = {}
- }
- local isVirus, virusError = xpcall(os.run, environment, filePath)
- _G["sleep"] = old_sleep
- return isVirus
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement