Sha256: fdd74c571ab52a44502fe8974ca11bdee82e62b9e5c7fafb140de9b56fa9a33c
Contents?: true
Size: 711 Bytes
Versions: 8
Compression:
Stored size: 711 Bytes
Contents
# frozen_string_literal: true module WPScan module Finders module InterestingFindings # UploadSQLDump finder class UploadSQLDump < CMSScanner::Finders::Finder SQL_PATTERN = /(?:DROP|CREATE|(?:UN)?LOCK) TABLE|INSERT INTO/.freeze # @return [ InterestingFinding ] def aggressive(_opts = {}) path = 'wp-content/uploads/dump.sql' res = target.head_and_get(path, [200], get: { headers: { 'Range' => 'bytes=0-3000' } }) return unless res.body =~ SQL_PATTERN Model::UploadSQLDump.new( target.url(path), confidence: 100, found_by: DIRECT_ACCESS ) end end end end end
Version data entries
8 entries across 8 versions & 1 rubygems