Sha256: 5c535d45ba176f78acbc05345564b5cbee7da79beb03cacbd188f15ce413af92

Contents?: true

Size: 1.01 KB

Versions: 16

Compression:

Stored size: 1.01 KB

Contents

class DradisTasks < Thor
  class Import < Thor
    class VulnDB < Thor
      namespace "dradis:import:vulndb"

      desc "private QUERY", "search a remote VulnDB instance with a general query"
      def private(query)
        require 'config/environment'

        results = Dradis::VulndbImport::Filters::VulnDB.run(:query => query)

        puts "VulnDB Search\n==============="
        puts "#{results.size} results\n"

        results.each do |record|
          puts "#{record[:title]}\n\t#{record[:description]}"
          puts "*" * 80
        end
      end

      desc "hq QUERY", "search your VulnDB HQ (http://vulndbhq.com) repository"
      def hq(query)
        require 'config/environment'

        results = Dradis::VulndbImport::Filters::VulnDB_HQ.run(:query => query)

        puts "VulnDB HQ Search\n==============="
        puts "#{results.size} results\n"

        results.each do |record|
          puts "#{record[:title]}\n\t#{record[:description]}"
          puts "*" * 80
        end
      end

    end
  end
end

Version data entries

16 entries across 16 versions & 1 rubygems

Version Path
dradis-vulndb-3.21.0 lib/tasks/thorfile.rb
dradis-vulndb-3.20.0 lib/tasks/thorfile.rb
dradis-vulndb-3.19.0 lib/tasks/thorfile.rb
dradis-vulndb-3.18.0 lib/tasks/thorfile.rb
dradis-vulndb-3.17.0 lib/tasks/thorfile.rb
dradis-vulndb-3.16.0 lib/tasks/thorfile.rb
dradis-vulndb-3.15.0 lib/tasks/thorfile.rb
dradis-vulndb-3.14.0 lib/tasks/thorfile.rb
dradis-vulndb-3.13.0 lib/tasks/thorfile.rb
dradis-vulndb-3.12.0 lib/tasks/thorfile.rb
dradis-vulndb-3.11.0 lib/tasks/thorfile.rb
dradis-vulndb-3.10.0 lib/tasks/thorfile.rb
dradis-vulndb-3.9.0 lib/tasks/thorfile.rb
dradis-vulndb-3.8.0 lib/tasks/thorfile.rb
dradis-vulndb-3.7.0 lib/tasks/thorfile.rb
dradis-vulndb-3.6.0 lib/tasks/thorfile.rb