Package core :: Package controllers :: Package basePlugin :: Module baseEvasionPlugin :: Class baseEvasionPlugin
[hide private]
[frames] | no frames]

Class baseEvasionPlugin




This is the base class for evasion plugins, all evasion plugins should inherit from it and implement the following methods :
  1. fuzzUrl(...)
  2. setOptions( OptionList )
  3. getOptionsXML()



Author: Andres Riancho ( andres.riancho@gmail.com )

Instance Methods [hide private]
  __eq__(self, other)
This function is called when sorting evasion plugins.
  __gt__(self, other)
This function is called when sorting evasion plugins.
  __init__(self)
  __lt__(self, other)
This function is called when sorting evasion plugins.
  fuzzUrl(self, path)
This method mangles the request url in order to evade simple IDSs.
  getPriority(self)
This function is called when sorting evasion plugins.
  getType(self)
  setUrlOpener(self, foo)
This method should not be overwritten by any plugin (but you are free to do it, for example a good idea is to rewrite this method to change the UrlOpener to do some IDS evasion technic).

Inherited from basePlugin.basePlugin: getDesc, getLongDesc, getName, getOptionsXML, getPluginDeps, printUniq, setOptions

Inherited from basePlugin.basePlugin (private): _sendMutant


Method Details [hide private]

__eq__(self, other)
(Equality operator)

 
This function is called when sorting evasion plugins.
Overrides: basePlugin.basePlugin.__eq__

__gt__(self, other)
(Greater-than operator)

 
This function is called when sorting evasion plugins.

__init__(self)
(Constructor)

 
None
Overrides: basePlugin.basePlugin.__init__

__lt__(self, other)
(Less-than operator)

 
This function is called when sorting evasion plugins.

fuzzUrl(self, path)

 

This method mangles the request url in order to evade simple IDSs.

This method MUST be implemented on every plugin.
Parameters:
  • path - This is the path to fuzz ( '/pepe/foo.asp?asl=00' )
Returns:
A fuzzed version of the path.

getPriority(self)

 
This function is called when sorting evasion plugins. Each evasion plugin should implement this.
Returns:
An integer specifying the priority. 100 is runned first, 0 last.

getType(self)

 
None
Overrides: basePlugin.basePlugin.getType

setUrlOpener(self, foo)

 

This method should not be overwritten by any plugin (but you are free to do it, for example a good idea is to rewrite this method to change the UrlOpener to do some IDS evasion technic).

This method takes a CustomUrllib object as parameter and assigns it to itself. Then, on the testUrl method you use self.CustomUrlOpener._custom_urlopen(...) to open a Url and you are sure that the plugin is using the user supplied settings (proxy, user agent, etc).
Returns:
No value is returned.
Overrides: basePlugin.basePlugin.setUrlOpener
(inherited documentation)