Class: CMSScanner::Finders::InterestingFindings::FantasticoFileslist

Inherits:
Finder
  • Object
show all
Defined in:
app/finders/interesting_findings/fantastico_fileslist.rb

Overview

FantasticoFileslist finder

Constant Summary

Constants inherited from Finder

Finder::DIRECT_ACCESS

Instance Attribute Summary

Attributes inherited from Finder

#progress_bar, #target

Instance Method Summary collapse

Methods inherited from Finder

#browser, #create_progress_bar, #found_by, #hydra, #initialize, #passive, #titleize

Constructor Details

This class inherits a constructor from CMSScanner::Finders::Finder

Instance Method Details

#aggressive(_opts = {}) ⇒ InterestingFinding

Returns:



12
13
14
15
16
17
18
19
# File 'app/finders/interesting_findings/fantastico_fileslist.rb', line 12

def aggressive(_opts = {})
  res = NS::Browser.get(url)

  return unless res&.code == 200 && !res.body.empty?
  return unless res.headers && res.headers['Content-Type'] =~ %r{\Atext/plain}

  NS::FantasticoFileslist.new(url, confidence: 70, found_by: found_by)
end

#urlString

Returns The url of the fantastico_fileslist.txt file.

Returns:

  • (String)

    The url of the fantastico_fileslist.txt file



7
8
9
# File 'app/finders/interesting_findings/fantastico_fileslist.rb', line 7

def url
  target.url('fantastico_fileslist.txt')
end