Sha256: e08fa446a88f714d7885037ba014bb78e01791d511fcc30fa6b27f6e3e695864
Contents?: true
Size: 561 Bytes
Versions: 25
Compression:
Stored size: 561 Bytes
Contents
module CMSScanner module Finders module InterestingFindings # Robots.txt finder class RobotsTxt < Finder # @return [ String ] The url of the robots.txt file def url target.url('robots.txt') end # @return [ InterestingFinding ] def aggressive(_opts = {}) res = NS::Browser.get(url) return unless res&.code == 200 && res.body =~ /(?:user-agent|(?:dis)?allow):/i NS::RobotsTxt.new(url, confidence: 100, found_by: found_by) end end end end end
Version data entries
25 entries across 25 versions & 1 rubygems