Sha256: 3df5a7bf95c3d01a09983cfb5ec959b2eec8e14ad4ce80ae36a98f816d860520

Contents?: true

Size: 710 Bytes

Versions: 3

Compression:

Stored size: 710 Bytes

Contents

module WPScan
  module Finders
    module WpVersion
      # Sitemap Generator Version Finder
      class SitemapGenerator < CMSScanner::Finders::Finder
        # @return [ WpVersion ]
        def aggressive(_opts = {})
          target.comments_from_page(%r{\Agenerator="wordpress/([^"]+)"\z}i, 'sitemap.xml') do |match, node|
            next unless WPScan::WpVersion.valid?(match[1])

            return WPScan::WpVersion.new(
              match[1],
              found_by: 'Sitemap Generator (Aggressive Detection)',
              confidence: 80,
              interesting_entries: ["#{target.url('sitemap.xml')}, #{node}"]
            )
          end
          nil
        end
      end
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
wpscan-3.0.2 app/finders/wp_version/sitemap_generator.rb
wpscan-3.0.1 app/finders/wp_version/sitemap_generator.rb
wpscan-3.0 app/finders/wp_version/sitemap_generator.rb