## Class IDS_Filter_Storage

Description

Filter Storage

This class provides various default functions for gathering filter patterns to be used later on by the detection mechanism. You might extend this class to your requirements.

- author: Lars Strojny <lars@strojny.net>
- author: Christian Matthies <ch0012@gmail.com>
- author: Mario Heiderich <mario.heiderich@gmail.com>
- version: Release: $Id:Storage.php 517 2007-09-15 15:04:13Z mario $
- copyright: 2007 The PHPIDS Group
- link: http://php-ids.org/
- license: LGPL

Located in /Filter/Storage.php (line 51)

Variable Summary
object IDS_Caching $cache
array $cacheSettings
array $filterSet
string $source
Method Summary
void __construct (IDS_Init $init)
object addFilter (IDS_Filter $filter)
object getFilterFromJson ()
object getFilterFromXML ()
array getFilterSet ()
object setFilterSet (array $filterSet)
Variables
object IDS_Caching $cache = null (line 73)

Cache container

- var: wrapper
- access: protected

array $cacheSettings = null (line 66)

Holds caching settings

- access: protected

array $filterSet = array() (line 80)

Filter container

- access: protected

string $source = null (line 59)

Filter source file

- access: protected

Methods
Constructor __construct (line 92)

Constructor

Loads filters based on provided IDS_Init settings.

- throws: Exception if unsupported filter type is given
- access: public

void __construct (IDS_Init $init)

- object $init: IDS_Init instance

addFilter (line 155)

Adds a filter

- access: public

object addFilter (IDS_Filter $filter)

- object $filter: IDS_Filter instance

getFilterFromJson (line 290)

Loads filters from Json file using ext/Json

This function parses the provided source file and stores the result. If caching mode is enabled the result will be cached to increase the performance.

- throws: Exception if problems with fetching the JSON data occur
- access: public

object getFilterFromJson ()
getFilterFromXML (line 190)

Loads filters from XML using SimpleXML

This function parses the provided source file and stores the result. If caching mode is enabled the result will be cached to increase the performance.

- throws: Exception if problems with fetching the XML data occur
- access: public

object getFilterFromXML ()
getFilterSet (line 143)

Returns registered filters

- access: public

array getFilterSet ()
setFilterSet (line 129)

Sets the filter array

- access: public

object setFilterSet (array $filterSet)

- array $filterSet: array containing multiple IDS_Filter instances

Documentation generated on Mon, 22 Dec 2008 13:36:53 +0100 by phpDocumentor 1.4.2