botherder/viper — pull request #136 by kevthehermit (2014-09-18 18:37:22+00:00)
Title: Fix for scan of 0 byte file

Yara Errors on a zero size file

```
[!] The command yara raised an exception:
Traceback (most recent call last):
File "/home/thehermit/GitHub/viper/viper/core/ui/console.py", line 201, in sta rt
module.run()
File "/home/thehermit/GitHub/viper/modules/yarascan.py", line 246, in run
self.scan()
File "/home/thehermit/GitHub/viper/modules/yarascan.py", line 136, in scan
for match in rules.match(entry_path):
Error: zero length file "../../temp/empty_file"
```

Files of no size can't be stored via the console but the api will store 0 byte files, which then breaks yara if you scan all files.