Mar
2012
Introducing Uirusu
I am pleased to announce that I have release Uirusu v0.0.1 as an replacement to my previous virustotal gem. This new gem is supports the v2 Virustotal API. The gem includes an example binary called uirusu as an example of how to use the API. Below I have included a few simplified examples of usage.
#First you need to include the correct require files
require 'rubygems'
require 'uirusu'
APT_KEY = "YOUR API KEY HERE"
hash = "FD287794107630FA3116800E617466A9" #Hash for a version of Poison Ivy
url = "http://www.google.com"
comment = "Hey this is Poison Ivy, anyone have a copy of this binary?"
#To query a hash(sha1/sha256/md5)
results = Uirusu::VTFile.query_report(APT_KEY, hash)
result = Uirusu::VTResult.new(hash, results)
print result.to_stdout if result != nil
#To scan for a url
results = Uirusu::VTUrl.query_report(APT_KEY, url)
result = Uirusu::VTResult.new(url, results)
print result.to_stdout if result != nil
#To post a comment to a resource(url/hash/scan_id)
results = Uirusu::VTComment.post_comment(APT_KEY, hash, comment)
print results if results != nil
For a more complex example take a look at the Uirusu::CLI::Application class, it covers uploading files/urls and waiting for them to be processed.
Installation
You can install uirusu with Rubygems, by typing gem install uirusu in your command prompt. Please see the project page for more information.
Issues
Please report any issues that are discovered and I will do my best to fix them in a timely manner.