Class: CMSScanner::Finders::Finder

Inherits:
Object
  • Object
show all
Defined in:
lib/cms_scanner/finders/finder.rb

Overview

Finder

Constant Summary collapse

DIRECT_ACCESS =

Constants for common found_by

'Direct Access (aggressive detection)'

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(target) ⇒ Finder

Returns a new instance of Finder.



10
11
12
# File 'lib/cms_scanner/finders/finder.rb', line 10

def initialize(target)
  @target = target
end

Instance Attribute Details

#targetObject

Returns the value of attribute target.



8
9
10
# File 'lib/cms_scanner/finders/finder.rb', line 8

def target
  @target
end

Instance Method Details

#aggressive(_opts = {}) ⇒ Object

Parameters:

  • _opts (Hash) (defaults to: {})


19
20
# File 'lib/cms_scanner/finders/finder.rb', line 19

def aggressive(_opts = {})
end

#found_byObject



22
23
24
# File 'lib/cms_scanner/finders/finder.rb', line 22

def found_by
  "#{self.class.to_s.demodulize} (#{caller_locations(1, 1)[0].label} detection)"
end

#passive(_opts = {}) ⇒ Object

Parameters:

  • _opts (Hash) (defaults to: {})


15
16
# File 'lib/cms_scanner/finders/finder.rb', line 15

def passive(_opts = {})
end