Testing TimThumb Script Detection Implementation in WPScan
This test suite validates the functionality of TimThumb script detection in WordPress installations through WPScan. It focuses on verifying the base finder implementation and known locations detection mechanism.
Test Coverage Overview
Implementation Analysis
Technical Details
Best Practices Demonstrated
wpscanteam/wpscan
spec/app/finders/timthumbs_spec.rb
# frozen_string_literal: true
describe WPScan::Finders::Timthumbs::Base do
subject(:timthumb) { described_class.new(target) }
let(:target) { WPScan::Target.new(url) }
let(:url) { 'http://ex.lo/' }
describe '#finders' do
it 'contains the expected finders' do
expect(timthumb.finders.map { |f| f.class.to_s.demodulize }).to eq %w[KnownLocations]
end
end
end