Want more features on Pastebin? Sign Up, it's FREE!
Guest

Untitled

By: a guest on Aug 27th, 2013  |  syntax: None  |  size: 1.14 KB  |  views: 23  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1. function namecheck()
  2. filelist = fs.list("/")
  3. names = {"cp", "dir", "ls", "mv", "rm", "computer", "http", "secret", "turtle", "bit", "colors", "colours", "gps", "help", "io", "parallel", "rednet", "term", "textutils", "vector", "os", "math", "fs", "coroutine", "parallel", "peripheral", "rs", "redstone", "shell", "string", "table", "term", "adventure", "hello", "worm", "pastebin", "alongtimeago", "dance", "excavate", "go", "tunnel", "turn"}
  4. for b = 1, #filelist do
  5. for i = 1, #names do
  6. if filelist[b] == names[i] then
  7. viruses = viruses+1
  8. files = files+1
  9. print("Virus "General.Malware" found in /" .. filelist[b])
  10. log("Virus "General.Malware" found in /" .. filelist[b])
  11. filemove("/" .. filelist[b], "/disk/bad" .. filelist[b])
  12. else
  13. end
  14. end
  15. end
  16. end
  17.  
  18. function syscheck()
  19. filelist = fs.list("/")
  20. system  = fs.list("/rom/programs")
  21. for b = 1, #filelist do
  22. for i = 1, #system do
  23. if filelist[b] == system[i] then
  24. viruses = viruses+1
  25. files = files+1
  26. print("Virus "General.Malware" found in /" .. filelist[b])
  27. log("Virus "General.Malware" found in /" .. filelist[b])
  28. filemove("/" .. filelist[b], "/disk/bad" .. filelist[b])
  29. else
  30. end
  31. end
  32. end
  33. end
clone this paste RAW Paste Data